Sahih al-Bukhari, Volume 8, Book 81, Hadith 763 (USC-MSA) ⓘ
Narrated Abu Huraira: Allah's Messenger said, "When an adulterer commits illegal sexual intercourse, then he is not a believer at the time he is doing it; and when somebody drinks an alcoholic drink, then he is not believer at the time of drinking, and when a thief steals, he is not a believer at the time when he is stealing; and when a robber robs and the people look at him, then he is not a believer at the time of doing it." Abu Huraira in another narration, narrated the same from the Prophet with the exclusion of robbery.
حَدَّثَنِي يَحْيَى بْنُ بُكَيْرٍ، حَدَّثَنَا اللَّيْثُ، عَنْ عُقَيْلٍ، عَنِ ابْنِ شِهَابٍ، عَنْ أَبِي بَكْرِ بْنِ عَبْدِ الرَّحْمَنِ، عَنْ أَبِي هُرَيْرَةَ، أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم قَالَ " لاَ يَزْنِي الزَّانِي حِينَ يَزْنِي وَهْوَ مُؤْمِنٌ، وَلاَ يَشْرَبُ الْخَمْرَ حِينَ يَشْرَبُ وَهْوَ مُؤْمِنٌ، وَلاَ يَسْرِقُ حِينَ يَسْرِقُ وَهْوَ مُؤْمِنٌ، وَلاَ يَنْتَهِبُ نُهْبَةً يَرْفَعُ النَّاسُ إِلَيْهِ فِيهَا أَبْصَارَهُمْ وَهْوَ مُؤْمِنٌ " . وَعَنِ ابْنِ شِهَابٍ، عَنْ سَعِيدِ بْنِ الْمُسَيَّبِ، وَأَبِي، سَلَمَةَ عَنْ أَبِي هُرَيْرَةَ، عَنِ النَّبِيِّ صلى الله عليه وسلم بِمِثْلِهِ، إِلاَّ النُّهْبَةَ.
also referenced under: Book 86, Hadith 1 (In-Book) & Hadith 6772 (DarusSalam)