Hadith 865 Asma bint Yazid
reported: The Prophet
passed by us when we were with a party of women, and he greeted us. [Abu Dawud].
Commentary: The permissibility of men to greet women, and vice versa, is with the condition that there will be no fear of temptation to commit the unlawful. Here are the details:
1. A young woman is forbidden to greet men and to respond to their greeting.
2. A group of women or an old woman are allowed to greet men and to respond to men's greetings. Men are also allowed to greet a group of women or an old woman.
3. A man on his own is not allowed to greet a young woman.
4. A man on his own is allowed to greet a group of women.
However, in all these cases, Islamic rules in this regard, including the lowering of the gaze, are to be observed.
For an explanation of this Hadith by Dr Muhammad Salah view the video included in Hadith No. 862 of Chapter 136