Some people raided the milk-camels of the Messenger of Allah ﷺ, so the Prophet ﷺ had their hands and feet cut off and their eyes gouged out.
إن قوما أغاروا على لقاح رسول الله ﷺ فقطع النبي ﷺ أيديهم وأرجلهم وسمل أعينهم.
Nasai (4038) and Ibn Majah (2579) both narrated it from Muhammad bin Muthanna, and Ibn Majah paired him with Muhammad bin Bashshar, from Ibrahim bin Abu Wazir, who said, "Darawardi narrated to us, from Hisham bin Urwa, from his father, from Ayesha," and he mentioned it. Its chain is hasan because of Darawardi, who is described as prone to error, except that he has been corroborated. Nasai (4037) narrated it through another route from Malik bin Shuayr, from Hisham with a chain similar to his, and Malik bin Shuayr is acceptable for corroborating narrations. It has also been narrated as mursal, but that does not harm what has come as a connected chain.This incident took place in the sixth year after the Hijrah. The shepherd's name was Yasar, a freed slave of the Messenger of Allah ﷺ. It is said that he was Nubian (a reference to the land of Nubia, which lies in southern Egypt). The Uraniyyin had cut off his hands and feet and thrust thorns into his tongue and eyes until he died, then brought him into Madinah dead. So the Messenger of Allah ﷺ did to them just as they had done.Among the points of jurisprudence in this hadith is that a group may be executed for killing one person. It is reported from Umar bin Khattab that he said, "If the people of Sanaa had all conspired together against him, I would have killed them all for him."Regarding them, Allah's statement was revealed, as mentioned in Sunan Abu Dawud (4366), "The punishment of those who wage war against Allah and His Messenger and strive to spread corruption in the land is that they be killed or crucified, or their hands and feet be cut off from opposite sides, or they be exiled from the land. That is disgrace for them in this world, and in the hereafter they will have a great punishment, except for those who repent before you overpower them. Know that Allah is forgiving and merciful" [Maidah 5:33–34]So the Prophet's ﷺ action matched the apparent sense of the verse, then the prohibition of mutilation came, as will follow.Some scholars held that the verse is definitive, and the matter is left to the ruler's discretion among execution, crucifixion, amputation, and exile. The first view is preferable, due to the established prohibition of mutilation. Imam Ahmad said, "Whoever kills is killed, and whoever takes property has his hand cut off."