Narrated Abdullah ibn Abbas: The Prophet ﷺ said: There is no prostitution in Islam. If anyone practised prostitution in pre-Islamic times, the child will be attributed to the master (of the slave-woman). He who claims his child without a valid marriage or ownership will neither inherit nor be inherited.
Hadith Referenceسنن ابي داود / كتاب تفريع أبواب الطلاق / 2264
Hadith Gradingالألبانی:ضعيف | زبیر علی زئی:ضعيف, إسناده ضعيف, ’’ بعض أصحابنا ‘‘ لم أعرفه وقال المنذري :’’ في إسناده رجل مجهول ‘‘ (عون المعبود 247/2), انوار الصحيفه، صفحه نمبر 86
Hadith Takhrij« تفرد بہ أبو داود، (تحفة الأشراف: 5656)، وقد أخرجہ: مسند احمد (1/362) (ضعیف) » (اس کے سند میں ایک مبہم راوی ہے)
Amr bin Shuaib on his father's authority said that his grandfather reported: The Prophet ﷺ decided regarding one who was treated as a member of a family after the death of his father, to whom he was attributed when the heirs said he was one of them, that if he was the child of a slave-woman whom the father owned when he had intercourse with her, he was included among those who sought his inclusion, but received none of the inheritance which was previously divided; he, however, received his portion of the inheritance which had not already been divided; but if the father to whom he was attributed had disowned him, he was not joined to the heirs. If he was a child of a slave-woman whom the father did not possess or of a free woman with whom he had illicit intercourse, he was not joined to the heirs and did not inherit even if the one to whom he was attributed is the one who claimed paternity, since he was a child of fornication whether his mother was free or a slave.
Hadith Referenceسنن ابي داود / كتاب تفريع أبواب الطلاق / 2265
Hadith Gradingالألبانی:حسن | زبیر علی زئی:إسناده حسن, مشكوة المصابيح (3318), أخرجه ابن ماجه (2746 وسنده حسن)
Hadith Takhrij« سنن ابن ماجہ/الفرائض 14 (2746)، (تحفة الأشراف: 8712)، وقد أخرجہ: مسند احمد (2/ 181، 219)، سنن الدارمی/الفرائض 45 (3154) (حسن) »
The tradition mentioned above has also been transmitted by Muhammad bin Rashid through a different chain of narrators to the same effect. This version adds “he is the child of fornication for the people of his mother whether she was free or a slave. This attribution of a child to the parents was practiced in the beginning of Islam. The property divided before Islam will not be taken into account.
Hadith Referenceسنن ابي داود / كتاب تفريع أبواب الطلاق / 2266
Hadith Gradingالألبانی:حسن | زبیر علی زئی:حسن, انظر الحديث السابق (2265)
Hadith Takhrij« انظر ما قبلہ، (تحفة الأشراف: 8712) (حسن) »