Sunan Ibn Majah 298
سنن ابن ماجه#298Sahihحَدَّثَنَا عَمْرُو بْنُ رَافِعٍ، حَدَّثَنَا إِسْمَاعِيلُ ابْنُ عُلَيَّةَ، عَنْ عَبْدِ الْعَزِيزِ بْنِ صُهَيْبٍ، عَنْ أَنَسِ بْنِ مَالِكٍ، قَالَ كَانَ رَسُولُ اللَّهِ ـ صلى الله عليه وسلم ـ إِذَا دَخَلَ الْخَلاَءَ قَالَ " أَعُوذُ بِاللَّهِ مِنَ الْخُبُثِ وَالْخَبَائِثِ " .
It was narrated that Anas bin Malik said:"Whenever the Messenger of Allah entered the toilet, he would say: 'A'udhu Billahi minal-khubthi wa'l-khaba'ith (I seek refuge with Allah from male and female devils)
Scholarly Authentication
The label above is the grade most of these scholars gave — one dissenting opinion no longer speaks for all of them. If any scholar calls a narration fabricated, that verdict is shown instead, whatever the others say. Each scholar's own wording:
In-book reference: 1:32