(9) باب الْبَيْعَةِ عَلَى الْجِهَادِ
It was narrated from 'Ubadah bin As-Samit that the Messenger of Allah said:
"Why don't you pledge to me upon that which the women have pledged: That you will not associate anything with Allah, that you will not steal, that you will not have unlawful sexual relations, that you will not utter slander, fabricating from between your hands and feet, and that you will not disobey me in goodness (Ma'ruf)?" We said: "yes, O Messenger of Allah." So we gave him our pledge, on that basis. The Messenger of Allah said: "Whoever commits any of these actions after that, and is punished, that will be an expiation. Whoever is not punished, then his affair is up to Allah; if He wills, He will forgive him, and if He wills, He will punish him."
Reference: Sunan an-Nasa'i 4162
In-book reference: Book 39, Hadith 14
English translation: Vol. 5, Book 39, Hadith 4167