Sunan an-Nasa'i, Volume 5, Book 39, Hadith 4183 (DarusSalam)

It was narrated that Abu Idris Al-Khawlani said: "I heard 'Ubadah bin As-Samit say: 'I pledged to the Messenger of Allah among a group of people, and he said: I accept your pledge that you will not associate anything with Allah, you will not steal, you will not have unlawful sexual relations, you will not kill you children, you will not utter slander, fabricating from between your hands and feet, and you will not disobey me when commanded with goodness. Whoever fulfills (this pledge), his reward will be with Allah, and whoever commits any of these actions and is punished for it, it will be purification for him. Whoever (commits any of these action then) Allah conceals him, it is up to Allah; if He wills He will forgive him, and if He wills, He will punish him."'

أَخْبَرَنَا يَعْقُوبُ بْنُ إِبْرَاهِيمَ، قَالَ حَدَّثَنَا غُنْدَرٌ، قَالَ أَنْبَأَنَا مَعْمَرٌ، قَالَ أَنْبَأَنَا ابْنُ شِهَابٍ، عَنْ أَبِي إِدْرِيسَ الْخَوْلاَنِيِّ، قَالَ سَمِعْتُ عُبَادَةَ بْنَ الصَّامِتِ، قَالَ بَايَعْتُ رَسُولَ اللَّهِ صلى الله عليه وسلم فِي رَهْطٍ فَقَالَ ‏ "‏ أُبَايِعُكُمْ عَلَى أَنْ لاَ تُشْرِكُوا بِاللَّهِ شَيْئًا وَلاَ تَسْرِقُوا وَلاَ تَزْنُوا وَلاَ تَقْتُلُوا أَوْلاَدَكُمْ وَلاَ تَأْتُوا بِبُهْتَانٍ تَفْتَرُونَهُ بَيْنَ أَيْدِيكُمْ وَأَرْجُلِكُمْ وَلاَ تَعْصُونِي فِي مَعْرُوفٍ فَمَنْ وَفَّى مِنْكُمْ فَأَجْرُهُ عَلَى اللَّهِ وَمَنْ أَصَابَ مِنْ ذَلِكَ شَيْئًا فَعُوقِبَ فِيهِ فَهُوَ طَهُورُهُ وَمَنْ سَتَرَهُ اللَّهُ فَذَاكَ إِلَى اللَّهِ إِنْ شَاءَ عَذَّبَهُ وَإِنْ شَاءَ غَفَرَ لَهُ ‏" ‏ ‏.‏

sunnah.com