كتاب المقدمات
The Book of Miscellany
(28)
Chapter: Covering Faults of the Muslims
(28)
- باب ستر عورات المسلمين والنهي عن إشاعتها لغير ضرورة
Riyad as-Salihin 241
Abu Hurairah (May Allah be pleased with him) reported:
Messenger of Allah (ﷺ) said, "Every one of my followers will be forgiven except those who expose (openly) their wrongdoings. An example of this is that of a man who commits a sin at night which Allah has covered for him, and in the morning, he would say (to people): "I committed such and such sin last night,' while Allah had kept it a secret. During the night Allah has covered it up but in the morning he tears up the cover provided by Allah Himself."

[Al-Bukhari and Muslim].

وعنه قال‏:‏ سمعت رسول الله صلى الله عليه وسلم يقول‏:‏ ‏ "‏كل أمتي معافًى إلا المجاهرين، وإن من المجاهرة أن يعمل الرجل بالليل عملاً، ثم يصبح وقد ستره الله عليه فيقول‏:‏ يا فلان عملت البارحة كذا وكذا، وقد بات يستره ربه، ويصبح يكشف ستر الله عنه‏"‏ ‏(‏‏(‏متفق عليه‏)‏‏)‏ ‏.‏
Reference : Riyad as-Salihin 241
In-book reference : Introduction, Hadith 241