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:17872Abū ʿAbdullāh al-Ḥāfiẓ > Abū ʿAbdullāh al-Ḥusayn b. al-Ḥasan b. Ayyūb al-Ṭūsī > Abū Ḥātim al-Rāzī > Ibn Abū Maryam > Muḥammad b. Jaʿfar > Zayd b. Aslam > ʿAṭāʾ b. Yasār > Abū Saʿīd al-Khudrī

[Machine] During the time of the Prophet Muhammad ﷺ , there were men among the hypocrites who would not join him when he went for battle. They would be happy to stay behind and go against the Prophet Muhammad's ﷺ orders. But when the Prophet Muhammad ﷺ returned, they would apologize to him, swear and pretend to have done things that they didn't do. Regarding them, the following was revealed in the Quran: "Do not think that those who rejoice in what they have done and love to be praised for what they have not done - do not think them unscathed from punishment." (Surah Al-Imran, 3:188)  

البيهقي:١٧٨٧٢أَخْبَرَنَا أَبُو عَبْدِ اللهِ الْحَافِظُ ثنا أَبُو عَبْدِ اللهِ الْحُسَيْنُ بْنُ الْحَسَنِ بْنِ أَيُّوبَ الطُّوسِيُّ ثنا أَبُو حَاتِمٍ الرَّازِيُّ ثنا ابْنُ أَبِي مَرْيَمَ ثنا مُحَمَّدُ بْنُ جَعْفَرٍ أَخْبَرَنِي زَيْدُ بْنُ أَسْلَمَ عَنْ عَطَاءِ بْنِ يَسَارٍ عَنْ أَبِي سَعِيدٍ الْخُدْرِيِّ ؓ

أَنَّ رِجَالًا مِنَ الْمُنَافِقِينَ فِي عَهْدِ رَسُولِ اللهِ ﷺ كَانَ إِذَا خَرَجَ النَّبِيُّ ﷺ إِلَى الْغَزْوِ تَخَلَّفُوا عَنْهُ وَفَرِحُوا بِمَقْعَدِهِمْ خِلَافَ رَسُولِ اللهِ ﷺ فَإِذَا قَدِمَ رَسُولُ اللهِ ﷺ اعْتَذَرُوا إِلَيْهِ وَحَلَفُوا وَأَحَبُّوا أَنْ يُحْمَدُوا بِمَا لَمْ يَفْعَلُوا فَنَزَلَتْ فِيهِمْ {لَا تَحْسَبَنَّ الَّذِينَ يَفْرَحُونَ بِمَا أَتَوْا وَيُحِبُّونَ أَنْ يُحْمَدُوا بِمَا لَمْ يَفْعَلُوا فَلَا تَحْسَبَنَّهُمْ بِمَفَازَةٍ مِنَ الْعَذَابِ} [آل عمران 188]  

رَوَاهُ الْبُخَارِيُّ فِي الصَّحِيحِ عَنْ سَعِيدِ بْنِ أَبِي مَرْيَمَ وَرَوَاهُ مُسْلِمٌ عَنِ الْحُلْوَانِيِّ وَابْنِ عَسْكَرٍ عَنِ ابْنِ أَبِي مَرْيَمَ قَالَ الشَّافِعِيُّ رَحِمَهُ اللهُ فَأَظْهَرَ اللهُ ﷻ لِرَسُولِهِ ﷺ أَسْرَارَهُمْ وَخَبَرَ السَّمَّاعِينَ لَهُمْ وَأَتْبَاعِهِمْ أَنْ يَفْتِنُوا مَنْ مَعَهُ بِالْكَذِبِ وَالْإِرْجَافِ وَالتَّخْذِيلِ لَهُمْ فَأَخْبَرَ أَنَّهُ كَرِهَ انْبِعَاثَهُمْ إِذَا كَانُوا عَلَى هَذِهِ النِّيَّةِ فَكَانَ فِيهَا مَا دَلَّ عَلَى أَنَّ اللهَ جَلَّ ثَنَاؤُهُ أَمَرَ أَنْ يُمْنَعَ مَنْ عُرِفَ بِمَا عُرِفُوا بِهِ مِنْ أَنْ يَغْزُوا مَعَ الْمُسْلِمِينَ؛ لِأَنَّهُ لَا ضَرَرَ عَلَيْهِمْ ثُمَّ زَادَ فِي تَأْكِيدِ بَيَانِ ذَلِكَ بِقَوْلِهِ {فَرِحَ الْمُخَلَّفُونَ بِمَقْعَدِهِمْ خِلَافَ رَسُولِ اللهِ} [التوبة 81] قَرَأَ إِلَى قَوْلِهِ {فَاقْعُدُوا مَعَ الْخَالِفِينَ} [التوبة 83]