It wasnarrated that 'Attab, the freed slave of Hurmuz, said:
"IheardAnas bin Malik say: 'We gave our pledge to the Messenger ofAllah(ﷺ) on the basis that we would listen and obey. He (ﷺ) said:"Asmuch as you can." (FR)
English reference (FR): Vol. 4, Book 24, Hadith 2868 (FR)
Arabic reference (FR): Book 24, Hadith 2978 (FR)