Sulayman ibn Buraydah reported on the authority of his father (Sayyidina Buraydah that when Allah’s Messenger (SAW) sent a commander with an army, he instructed him to fear Allah himself particularly and be mindful of the good of the Muslims with him. He would also say. Go fight in the name of Allah and in His path. Fight those who disbelieve in Allah. Do not be unfaithful regarding the spoils, do not be treacherous and do not mutilate anyone and do not kill children. When you meet your enemy among the polytheists, invite them to one of the three things, and whichever of these they agree, accept that from them and refrain (to fight) from them. Invite them to Islam and to migrate from their areas to the regions of the Muhajirs and inform them that if they do that then for them is that which is for the Muhajirs, and the same responsibilities as for the Muhajirs. If they refuse to migrate then inform them that they will he like the Muslims of the deserts and the same injunctions will apply to them as to the desert Muslims, and they will have no share in booty or fai unless they participate in jihad. But, if they refuse then seek Allah’s help against them and fight them. So, if you surround a fort and they seek the protection of Allah and His Messenger then do not give it to them, but give them your protection and the profection of your friends, for, if you retract from your protection and the protection of your friends then that is better than your violating the protection of Allah and His Messenger . And if you have beseiged the people in a fort and they wish you to judge according to Allah’s commands then do not do it, but decide within your orbit because you do not know what the command of Allah is and whether you follow Allah’s commands or not in deciding the matter.”
[Muslim 1731, Abu Dawud 2612, Ibn e Majah 2858, Ahmed 23039]