While the Messenger of Allah ﷺ was sitting in the mosque with people gathered around him, three men approached. Two of them came toward the Messenger of Allah ﷺ while the third went away. When the two stopped at the gathering of the Messenger of Allah ﷺ, they greeted him with peace. One of them saw a gap in the circle and sat in it, while the other sat behind the gathering, and the third turned away and left.When the Messenger of Allah ﷺ finished, he said, "Shall I tell you about these three men? As for one of them, he sought refuge with Allah, so Allah gave him refuge. As for the other, he felt shy, so Allah was shy with him. And as for the last, he turned away, so Allah turned away from him."
أن رسول الله ﷺ بينما هو جالس في المسجد والناس معه، إذ أقبل نفر ثلاثة، فأقبل اثنان إلى رسول الله ﷺ وذهب واحد، فلما وقفا على مجلس رسول الله ﷺ سلما، فأما أحدهما فرأى فرجة في الحلقة فجلس فيها، وأما الآخر فجلس خلفهم، وأما الثالث فأدبر ذاهبا، فلما فرغ رسول الله ﷺ قال: ألا أخبركم عن النفر الثلاثة؟ أما أحدهم فآوى إلى الله فآواه الله، وأما الآخر فاستحيا فاستحيا الله منه، وأما الآخر فأعرض فأعرض الله عنه.
Malik reported it in "Salam" (4), from Ishaq bin Abdullah bin Abu Talha, from Abu Mura, the freed slave of Aqeel bin Abu Talib, from Abu Waqid Laythi, and he mentioned it. Bukhari reported it in "Ilm" (66) and Muslim in "Salam" (2176), both of them from Malik with the same chain.