Hadith 2156

Abu Al Darda said “The Apostle of Allaah(saws) was in a battle. He saw a woman who was nearing the time when she was to deliver a child. “He said “Perhaps the master has intercourse with her.”. They(the people) said “Yes”. He said “I am inclined to invoke a curse on him which will enter his grave with him. How can he make it (the child) an heir when it is not lawful for him? How can he take it into his service when that is not lawful for him?”

حَدَّثَنَا النُّفَيْلِيُّ، حَدَّثَنَا مِسْكِينٌ، حَدَّثَنَا شُعْبَةُ، عَنْ يَزِيدَ بْنِ خُمَيْرٍ، عَنْ عَبْدِ الرَّحْمَنِ بْنِ جُبَيْرِ بْنِ نُفَيْرٍ، عَنْ أَبِيهِ، عَنْ أَبِي الدَّرْدَاءِ، أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم كَانَ فِي غَزْوَةٍ فَرَأَى امْرَأَةً مُجِحًّا فَقَالَ ‏"‏ لَعَلَّ صَاحِبَهَا أَلَمَّ بِهَا ‏"‏ ‏.‏ قَالُوا نَعَمْ ‏.‏ فَقَالَ ‏"‏ لَقَدْ هَمَمْتُ أَنْ أَلْعَنَهُ لَعْنَةً تَدْخُلُ مَعَهُ فِي قَبْرِهِ كَيْفَ يُوَرِّثُهُ وَهُوَ لاَ يَحِلُّ لَهُ وَكَيْفَ يَسْتَخْدِمُهُ وَهُوَ لاَ يَحِلُّ لَهُ ‏"‏ ‏.‏

Reference: 921590
In-book reference: Book 12, Hadith 2156
Hadith 2156 - Marriage (Kitab Al-Nikah) - Sunan Abi Dawud - Sunnah.com