"A man from Banu Sulaim who had some sheep with him, passed by some of the Companions of the Messenger of Allah ﷺ. He gave Salam to them and they said: 'He did not give Salam except to protect himself.' So they attacked him, killed him, and took his sheep. They went to the Messenger of Allah ﷺ with them, and Allah, Most High, revealed: O you who believe! When you go in the cause of Allah, verify and say not to anyone who greets you: "You are not a believer (4:94)." (Using translation from Tirmidhī 3030)
مَرَّ رَجُلٌ مِنْ بَنِي سُلَيْمٍ عَلَى نَفَرٍ مِنْ أَصْحَابِ النَّبِيِّ ﷺ وَمَعَهُ غَنَمٌ لَهُ فَسَلَّمَ عَلَيْهِمْ فَقَالُوا مَا سَلَّمَ عَلَيْكُمْ إِلَّا لِيَتَعَوَّذَ مِنْكُمْ فَعَمَدُوا إِلَيْهِ فَقَتَلُوهُ وَأَخَذُوا غَنَمَهُ فَأَتَوْا بِهَا النَّبِيَّ ﷺ فَأَنْزَلَ اللَّهُ تَعَالَى {يَا أَيُّهَا الَّذِينَ آمَنُوا إِذَا ضَرَبْتُمْ فِي سَبِيلِ اللَّهِ فَتَبَيَّنُوا وَلَا تَقُولُوا لِمَنْ أَلْقَى إِلَيْكُمُ السَّلَامَ لَسْتَ مُؤْمِنًا} [النساء 94] إِلَى قَوْلِهِ {كَذَلِكَ كُنْتُمْ مِنْ قَبْلُ فَمَنَّ اللَّهُ عَلَيْكُمْ فَتَبَيَّنُوا} [النساء 94]