Sunnah.com reference : Book 10, Hadith 3English translation : Book 10, Hadith 1246Arabic reference : Book 10, Hadith 1207
Abu Hurairah (RAA) narrated, 'A Muslim man came to the Prophet (ﷺ) while he was in the mosque, and called him saying, 'O Messenger of Allah! I have committed adultery.' The Messenger of Allah (ﷺ) turned his face away from him, so the man came round (from the other side) towards his face and said, 'O Messenger of Allah! I have committed adultery.' The Messenger of Allah (ﷺ) again turned his face away from him, but the man repeated his statement four times. When he testified four times that he did it, the Messenger of Allah (ﷺ) called him saying, "Are you insane?" The man said, 'No.' The Messenger of Allah (ﷺ) then asked him, "Are you married?" The man answered, 'Yes.' The Messenger of Allah (ﷺ) said:
"Take him away and stone him (to death)." Agreed upon.
وَعَنْ أَبِي هُرَيْرَةَ ‏- رضى الله عنه ‏- قَالَ: { أَتَى رَجُلٌ مِنْ اَلْمُسْلِمِينَ رَسُولُ اَللَّهِ ‏- صلى الله عليه وسلم ‏-‏-وَهُوَ فِي اَلْمَسْجِدِ‏- فَنَادَاهُ فَقَالَ: يَا رَسُولَ اَللَّهِ! إِنِّي زَنَيْتُ, فَأَعْرَضَ عَنْهُ, فَتَنَحَّى تِلْقَاءَ وَجْهِهِ, فَقَالَ: يَا رَسُولَ اَللَّهِ! إِنِّي زَنَيْتُ, فَأَعْرَضَ عَنْهُ, حَتَّى ثَنَّى ذَلِكَ عَلَيْهِ أَرْبَعَ مَرَّاتٍ, فَلَمَّا شَهِدَ عَلَى.‏  1‏ نَفْسِهِ أَرْبَعَ شَهَادَاتٍ.‏ دَعَاهُ رَسُولُ اَللَّهِ ‏- صلى الله عليه وسلم ‏-فَقَالَ "أَبِكَ جُنُونٌ?" قَالَ.‏ لَا.‏ قَالَ: "فَهَلْ  2‏ أَحْصَنْتَ?".‏ قَالَ: نَعَمْ.‏ فَقَالَ رَسُولُ اَللَّهِ ‏- صلى الله عليه وسلم ‏-"اِذْهَبُوا بِهِ فَارْجُمُوهُ" }  مُتَّفَقٌ عَلَيْهِ  3‏ .‏‏1 ‏- تحرف في "أ" إلى "عليه".‏‏2 ‏- تحرف في "أ" إلى: "فها".‏‏3 ‏- صحيح رواه البخاري (5271)‏، ومسلم (1691)‏ (16)‏.‏