Hadith on Hudud: Private repentance accepted to avoid legal punishment

Zayd ibn Aslam reported: A man confessed of adultery in the time of the Messenger of Allah, peace and blessings be upon him. The Prophet called for a whip and he was given a broken whip. The Prophet said, “Greater than this.” He was brought another whip whose knots had not been cut. The Prophet said, “Lesser than this.” He was brought a whip that had been used and was more flexible. The Prophet gave the order and the man was flogged, then the Prophet said, “O people, the time has now come for you to observe the limits of Allah. Whoever has had any of these ugly matters befall him should cover them up with the veil of Allah. Whoever reveals to us his sins, we will act against him according to the Book of Allah.”

Source: al-Muwaṭṭa’ 1562

Grade: Hasan li ghayri (fair due to external evidence) according to Ibn Hajar

عَنْ زَيْدِ بْنِ أَسْلَمَ أَنَّ رَجُلًا اعْتَرَفَ عَلَى نَفْسِهِ بِالزِّنَا عَلَى عَهْدِ رَسُولِ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَدَعَا لَهُ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ بِسَوْطٍ فَأُتِيَ بِسَوْطٍ مَكْسُورٍ فَقَالَ فَوْقَ هَذَا فَأُتِيَ بِسَوْطٍ جَدِيدٍ لَمْ تُقْطَعْ ثَمَرَتُهُ فَقَالَ دُونَ هَذَا فَأُتِيَ بِسَوْطٍ قَدْ رُكِبَ بِهِ وَلَانَ فَأَمَرَ بِهِ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَجُلِدَ ثُمَّ قَالَ أَيُّهَا النَّاسُ قَدْ آنَ لَكُمْ أَنْ تَنْتَهُوا عَنْ حُدُودِ اللَّهِ مَنْ أَصَابَ مِنْ هَذِهِ الْقَاذُورَاتِ شَيْئًا فَلْيَسْتَتِرْ بِسِتْرِ اللَّهِ فَإِنَّهُ مَنْ يُبْدِي لَنَا صَفْحَتَهُ نُقِمْ عَلَيْهِ كِتَابَ اللَّهِ

1562 موطأ مالك كتاب الحدود باب ما جاء فيمن اعترف على نفسه بالزنا

4/1400 المحدث ابن حجر العسقلاني خلاصة حكم المحدث مرسل له شاهد عند عبد الرزاق وآخر يشد بعضها بعضا في التلخيص الحبير