Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:18099Abū Saʿīd b. Abū ʿAmr > Abū al-ʿAbbās > al-Rabīʿ > al-Shāfiʿī

[Machine] Imam Shafi'i said in the narration of Anas, "Indeed, the Prophet ﷺ would not initiate hostilities unless it became permissible to raid at night or during the day, and to attack enemies in any situation. Allah knows best, but he would have the ability to observe those with him, so that they could change their plans to protect themselves from ambushes or attacks that they do not expect. Sometimes, during a night raid, the situation could become chaotic and some Muslims would unintentionally kill others. This happened in the killing of Ibn 'Atik, where one of them accidentally severed another's leg. Imam Shafi'i said, 'Indeed, the Prophet ﷺ ordered raids on more than one occasion against the Jews, and they were killed.'"  

البيهقي:١٨٠٩٩وَأَخْبَرَنَا أَبُو سَعِيدِ بْنُ أَبِي عَمْرٍو ثنا أَبُو الْعَبَّاسِ أنبأ الرَّبِيعُ قَالَ

قَالَ الشَّافِعِيُّ فِي رِوَايَةِ أَنَسٍ إِنَّ النَّبِيَّ ﷺ كَانَ لَا يُغِيرُ حَتَّى يُصْبِحَ لَيْسَ بِتَحْرِيمٍ لِلْإِغَارَةِ لَيْلًا وَلَا نَهَارًا وَلَا غَارِّينَ فِي حَالٍ وَاللهُ أَعْلَمُ وَلَكِنَّهُ عَلَى أَنْ يَكُونَ يُبْصِرُ مَنْ مَعَهُ كَيْفَ يُغِيرُونَ احْتِيَاطًا مِنْ أَنْ يُؤْتَوْا مِنْ كَمِينٍ أَوْ مِنْ حَيْثُ لَا يَشْعُرُونَ وَقَدْ يَخْتَلِطُ الْحَرْبُ إِذَا أَغَارُوا لَيْلًا فَيَقْتُلُ بَعْضُ الْمُسْلِمِينَ بَعْضًا قَدْ أَصَابَهُمْ ذَلِكَ فِي قَتْلِ ابْنِ عَتِيكٍ فَقَطَعُوا رِجْلَ أَحَدِهِمْ قَالَ الشَّافِعِيُّ ؓ قَدْ أَمَرَ النَّبِيُّ ﷺ بِالْغَارَةِ عَلَى غَيْرِ وَاحِدٍ مِنْ يَهُودَ فَقَتَلُوهُ