It was narrated from Ibn 'Abbas that the Prophet (ﷺ) said:”A believer should not be killed in retaliation for the murder of a disbeliever, and a person who has a treaty should not be killed during the time of the treaty.”
Hadith No. 2660
Sunan Ibn Majah
Gradings:
Al-Albani:
Sahih
Muhammad Fouad Abd al-Baqi:
Sahih
Zubair Ali Zai:
Daif