Ayesha reported,

Barirah came to Ayesha while she was a slave under a contract of manumission. Her owners had agreed to free her in exchange for nine ounces of silver. Ayesha said to her, "If your owners agree, I will pay them the entire sum at once, and the right of inheritance from you will belong to me."Barirah went to her owners and mentioned this to them, but they refused unless the right of inheritance was stipulated for them. Ayesha mentioned this to the Prophet ﷺ, who said, "Go ahead." So she did.Then the Prophet ﷺ stood up and addressed the people. He praised Allah and extolled Him, then said, "What is the matter with Some men who stipulate conditions that are not found in the Book of Allah? Any condition not found in the Book of Allah is invalid. The Book of Allah has the greater claim, and His condition is the firmer. The right of inheritance belongs to the one who frees the slave."

Ahmad 25786

Sahih

حدثنا وكيع قال حدثنا هشام عن أبيه

عن عائشة

أن بريرة أتتها وهي مكاتبة قد كاتبها أهلها على تسع أواق فقالت لها إن شاء أهلك عددتها لهم عدة واحدة وكان الولاء لي فأتت أهلها فذكرت ذلك لهم وأبوا إلا أن يشترطوا الولاء لهم فذكرته عائشة للنبي ﷺ فقال افعلي ففعلت فقام النبي ﷺ فخطب الناس فحمد الله وأثنى عليه قال ما بال رجال يشترطون شروطا ليست في كتاب الله قال كل شرط ليس في كتاب الله فهو باطل كتاب الله أحق وشرطه أوثق والولاء لمن أعتق

أحمد 25786صحيح
Contents
Reference
Commentary
Ayat
Collection
Musnad Ahmad
Book
Ayesha
Numbering
Darussalam 25786
Ahmad 25786