كتاب المقدمات
The Book of Miscellany
(49)
Chapter: Making Judgment of people keeping in view their evident actions and leaving their hidden Actions to Allah (swt)
(49)
- باب إجراء أحكام الناس على الظاهر وسرائرهم إلى الله تعالى
Riyad as-Salihin 390
'Abdullah bin 'Umar (May Allah be pleased with them) reported:
Messenger of Allah (ﷺ) said, "I have been commanded (by Allah) to fight people until they testify that there is no true god except Allah, and that Muhammad is the Messenger of Allah, and perform Salat and pay Zakat. If they do so, they will have protection of their blood and property from me except when justified by Islam, and then account is left to Allah".

[Al-Bukhari and Muslim].

وعن ابن عمر رضي الله عنهما، أن رسول الله صلى الله عليه وسلم قال‏:‏ ‏ "‏أمرت أن أقاتل الناس حتى يشهدوا أن لا إله إلا الله ، وأن محمداً رسول الله ، ويقيموا الصلاة، ويؤتوا الزكاة ، فإذا فعلوا ذلك عصموا مني دماءهم وأموالهم إلا بحق الإسلام، وحسابهم على الله تعالى‏"‏ ‏(‏‏(‏متفق عليه‏)‏‏)‏ ‏.‏
Reference : Riyad as-Salihin 390
In-book reference : Introduction, Hadith 390