The Messenger of Allah ﷺ cursed effeminate men who imitate women, masculine women who imitate men, and the one who travels alone through the wilderness.
حدثنا أيوب بن النجار أبو إسماعيل اليمامي عن طيب بن محمد عن عطاء بن أبي رباح
لعن رسول الله ﷺ مخنثي الرجال الذين يتشبهون بالنساء والمترجلات من النساء المتشبهين بالرجال وراكب الفلاة وحده
Its isnad is sahih. Ayub bin Najjar bin Ziyad bin Najjar Hanafi, Abu Ismail, judge of Yamamah, is trustworthy, one of the best of people. Ahmad said, a trustworthy shaykh, a righteous and chaste man. He is discussed by Bukhari in al-Kabir 1/1/425, Ibn Saad 5/405, and Ibn Abu Hatim 1/1/260.Tayyib bin Muhammad Yamami is trustworthy. Ibn Hibban mentioned him among the trustworthy, p. 505. Aqeeli deemed him daif. Abu Hatim said, he is not known. He is discussed in al-Kabir 2/2/363, Ibn Abu Hatim 2/1/498, al-Tajil p. 200, and Lisan Mizan 3/214.This hadith will come again with this same isnad at 7878, at greater length, with the addition of the curse upon men and women who abstain from marriage. It also appears in Jami al-Masanid 7/293 quoting the longer version, and Haythami mentioned it in Majma al-Zawaid 4/251, also quoting the longer version. He said, Ahmad narrated it, and it contains Tayyib bin Muhammad, whom Ibn Hibban deemed trustworthy while Aqeeli deemed him daif, and the rest of its narrators are narrators of the Sahih.Bukhari narrated it in al-Kabir, in the entry on Tayyib, and criticized it by citing the hadith of Abdullah bin Amr, as a saying of the Prophet, "None of us is he among the men who imitates women..." and so on. This has already been discussed at 6875. Bukhari then said, and the hadith of Abu Hurairah is not sound.This criticism from Bukhari, may Allah have mercy on him, is not complete. For this is one hadith and that is another. There is nothing preventing Ataa from narrating both this one and that one. The two are not identical in meaning, even though they share some meaning in common. Rather, one of them supports and strengthens the other.See, regarding the prohibition of being alone, what has already passed in the hadith of Abdullah bin Umar at 6014, and in the hadith of Abdullah bin Amr at 7007.