Initiating the salam to the people of the book and responding to their salam?
Ibn al Qayyim said:
وقد اختلف السلف والخلف في ذلك ، فقال أكثرهم : لا يبدءون بالسلام ، وذهب آخرون إلى جواز ابتدائهم كما يرد عليهم ، روي ذلك عن ابن عباس ، وأبي أمامة ، وابن محيريز ، وهو وجه في مذهب الشافعي رحمه الله لكن صاحب هذا الوجه قال : يقال له : السلام عليك فقط بدون ذكر الرحمة ، وبلفظ الإفراد ، وقالت طائفة : يجوز الابتداء لمصلحة راجحة من حاجة تكون له إليه ، أو خوف من أذاه ، أو لقرابة بينهما ، أو لسبب يقتضي ذلك ، يروى ذلك عن إبراهيم النخعي ، وعلقمة .
وقال الأوزاعي : إن سلمت فقد سلم الصالحون ، وإن تركت فقد ترك الصالحون .
واختلفوا في وجوب الرد عليهم ، فالجمهور على وجوبه ، وهو الصواب ، وقالت طائفة : لا يجب الرد عليهم ، كما لا يجب على أهل البدع وأولى ، والصواب الأول ، والفرق أنا مأمورون بهجر أهل البدع تعزيرا لهم وتحذيرا منهم ، بخلاف أهل الذمة .
وثبت عنه صلى الله عليه وسلم أنه ( مر على مجلس فيه أخلاط من المسلمين ، والمشركين عبدة الأوثان ، واليهود ، فسلم عليهم ) .
وصح عنه أنه كتب إلى هرقل وغيره ( السلام على من اتبع الهدى )
The salaf and khalaf differed in this case, many of them said, Do not initiate salam and others say it is allowed to initiate the salam for kind. This is narrated from Ibn Abbas, Abi Amama, Ibn Muhayreez and this is one of the opinion in the madhab of ash-Shafiee May Allah have mercy on him, but the one who have this opinion said: Say to him May peace be upon you rather than saying (Peace be upon you) and mercy.
And A group (of scholars) said: it is allowed to initiate the salam due to some purpose, like due to some interest that one intends to achieve, or because one fears the harm, or because they are relatives, or due to some other reasons like this, this is narrated from Ibraheem an-Nakh`ee and Alqama.
al Awzaai said: If you greet then the righteous have greeted, and if you left then the righteous have left.
And they (the scholars) differed as to whether it is obligatory to return the greeting. The majority said that it is obligatory and this is the correct view. A group of scholars said that it is not obligatory to return their greeting just as it is not obligatory to return the greeting of those who follow bid’ah. But the correct view is the first one. The difference is that we are commanded to forsake the followers of bid’ah by way of rebuke and to warn others about them, which is not the case with the Ahl al-Dhimmah (Jews and Christians). (Ibn al Qayyim said: “he should say in return ‘wa ‘alayka al-salaam’, because this is more just, and Allaah commands us to be just and to treat others well” see his book Ahkaam Ahl al-Dhimmah, 1/425, Islamqa)
And it is proven from the Prophet peace be upon him: He passed by a group where Muslims, Mushriq, Idol worshipers, Jews were sitting, and He peace be upon him said salam to them.
And it is authentically proven from him (peace be upon him) that when he wrote a letter to Hiraql (chief of Byzantines) and others (starting with) “Peace be to those who follow the guidance.”
(Zaad al-Ma’aad, 2/425, 426)