Abu Hurayrah reported the Prophet ﷺ as saying, "A thief does not steal while he is a believer, a drinker does not drink wine while he is a believer, and a fornicator does not commit fornication while he is a believer."
حدثنا سفيان عن أبي الزناد عن الأعرج
يبلغ به النبي ﷺ لا يسرق حين يسرق وهو مؤمن ولا يشرب الخمر حين يشربها وهو مؤمن ولا يزني حين يزني وهو مؤمن
Its chain of transmission is sahih. Bukhari also narrated it, at length and abridged, in 5:86 and 10:28–29, and 12:50, 101, and Muslim narrated it in 1:31–32 through other routes. Al-Hafiz commented on it thoroughly in 12:50–54.