Abu Al Darda said “The Apostle of Allaah ﷺ 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?” (Using translation from Abū Dāʾūd 2156)
أَنَّ النَّبِيَّ ﷺ رَأَى امْرَأَةً مُجِحًّا عَلَى بَابِ فُسْطَاطٍ أَوْ طَرَفِ فُسْطَاطٍ فَقَالَ رَسُولُ اللهِ ﷺ لَعَلَّ صَاحِبَهَا يُلِمُّ بِهَا قَالُوا نَعَمْ قَالَ لَقَدْ هَمَمْتُ أَنْ أَلْعَنَهُ لَعْنَةً تَدْخُلُ مَعَهُ فِي قَبْرِهِ كَيْفَ يُوَرِّثُهُ وَهُوَ لَا يَحِلُّ لَهُ؟ وَكَيْفَ يَسْتَخْدِمُهُ وَهُوَ لَا يَحِلُّ لَهُ؟