Hadithcore
Sunan Abi Dawud, 5115
sahih· Al-Albani

Anas b. Malik reported the Messenger of Allah (ﷺ) as saying:

If anyone pretends to be the son of a man other than his father, or attributes his freedom to people other than those who set him free, on him will be the curse of Allah that will continue till the day of resurrection.

حَدَّثَنَا سُلَيْمَانُ بْنُ عَبْدِ الرَّحْمَنِ الدِّمَشْقِيُّ، حَدَّثَنَا عُمَرُ بْنُ عَبْدِ الْوَاحِدِ، عَنْ عَبْدِ الرَّحْمَنِ بْنِ يَزِيدَ بْنِ جَابِرٍ، قَالَ حَدَّثَنِي سَعِيدُ بْنُ أَبِي سَعِيدٍ، - وَنَحْنُ بِبَيْرُوتَ - عَنْ أَنَسِ بْنِ مَالِكٍ، قَالَ سَمِعْتُ رَسُولَ اللَّهِ صلى الله عليه وسلم يَقُولُ ‏

‏ مَنِ ادَّعَى إِلَى غَيْرِ أَبِيهِ أَوِ انْتَمَى إِلَى غَيْرِ مَوَالِيهِ فَعَلَيْهِ لَعْنَةُ اللَّهِ الْمُتَتَابِعَةُ إِلَى يَوْمِ الْقِيَامَةِ ‏

‏ ‏.‏

References2 variants
In-Book Reference
Book 43, Hadith 343
English Reference
Book 42, Hadith 5096