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."
English reference: Vol. 4, Book 24, Hadith 2868
Arabic reference: Book 24, Hadith 2978