On the recommendation to give the greeting when leaving an assembly and parting from one's companions

Riyad as-Salihin (The Meadows of the Righteous)

by Imam Nawawi

139. Chapter: On the recommendation to give the greeting when leaving an assembly and parting from one's companions

869. Abu Hurayra reported that the Messenger of Allah, may Allah bless him and grant him peace, said, "When one of you comes to a gathering, he should give the greeting. When he wants to get up, he should also give the greeting. The former is no more of a duty than the latter." [Abu Dawud and at-Tirmidhi]