Another report on this matter—although its chain is somewhat unusual—reads as follows:
Al-Bayhaqī said: Abū ʿAbd Allāh al-Ḥāfiẓ and Muḥammad ibn al-Ḥusayn ibn Dāwūd al-ʿAlawī informed us, saying: Abū al-ʿAbbās Muḥammad ibn Yaʿqūb al-Umawī narrated to us; Muḥammad ibn ʿUbayd ibn ʿUtbah al-Kindī narrated to us; Muḥammad ibn al-Ṣalt narrated to us; Ḥibbān narrated to us; Abū Saʿīd al-Baqqāl narrated to us, from ʿIkrimah, from Ibn ʿAbbās—may Allah be pleased with them—who said:
Whenever the Messenger of Allah ﷺ needed to relieve himself, he would go far away. One day he withdrew, sat beneath a samura-tree, and removed his two leather socks. After putting on one of them, a bird swooped down, snatched the other, and flew into the sky; from the sock a black snake slipped out. The Messenger of Allah ﷺ remarked, “This is a mark of honour with which Allah has favoured me. O Allah, I seek refuge in You from the evil of whatever walks upon two legs and from the evil of whatever crawls upon its belly.”
Chapter: The incident of the two Companions whose staffs gave off light when they left the Prophet ﷺ
Al-Bukhārī said: Muḥammad ibn al-Muthannā related to us; Muʿādh related to us; my father related to me, from Qatādah, who said that Anas ibn Mālik narrated:
Two men from the Companions of the Prophet ﷺ left him on a pitch-black night. Before them were lights like two lamps. When they parted ways, one of those lights remained with each man until he reached his house.
ʿAbd al-Razzaq reported: Maʿmar informed us, from Thābit, from Anas, that Usayd ibn Ḥuḍayr al-Anṣārī and another Anṣārī were speaking with the Prophet ﷺ about a particular matter until a portion of the night had passed. The night was extremely dark. When they departed, each of them was carrying a small stick. The stick of one of them began to shine, lighting the way for both until their paths diverged; then the other man’s stick shone, and each of them walked on by the light of his own stick until he arrived safely at his family home.