I then found the hadith in al-Bayhaqī’s Shuʿab al-Īmān, where he relates it (2/173/2) through ʿAbd al-Wāḥid ibn Zayd, from Aslam al-Kūfī, with the same wording. Thus, all that remains is to examine the chain of transmission in al-Muʿjam al-Awsaṭ, which I presume to be through this very route; I hope that I shall be enabled to locate it. Nevertheless, I consider the hadith authentic, for it has corroborating reports, the strongest of which is the hadith of Jābir ibn ʿAbd Allāh, narrated from him by ʿAbd al-Raḥmān ibn Sābiṭ, who said: Jābir ibn ʿAbd Allāh told me: I heard the Messenger of Allah ﷺ say:
“O Kaʿb ibn ʿUjrah! No one whose flesh has grown from ill-gotten wealth shall enter Paradise; the Fire has a greater right to him. O Kaʿb ibn ʿUjrah ...” [the rest of the hadith].
It was recorded by al-Dārimī (2/318), Ibn Ḥibbān (1569 and 1570), al-Ḥākim (4/127), and al-Bayhaqī in al-Shuʿab (2/173/2), whose version supplies the wording; and by Aḥmad (3/399 and 321), through ʿAbd Allāh ibn ʿUthmān ibn Khuthaym, from him. I say: This is a good chain of transmission, meeting Muslim’s conditions. Ibn Sābiṭ explicitly stated in it that he heard it from Jābir, which refutes what is related in his biographical notice from Ibn Maʿīn, who said: “He did not hear from him.”
It also has two other routes from Jābir: one is recorded by al-Bayhaqī, and the other by al-Tirmidhī (1/119), who said: “A good, singular hadith through this route.” I then located its chain of transmission in al-Muʿjam al-Awsaṭ (2/65/1), and there it is exactly as in al-Shuʿab!