It is narrated from Sayyiduna Anas bin Malik (may Allah be pleased with him) that the Prophet (peace and blessings be upon him) said: "The leaders (imams) will be from Quraysh as long as they act with justice when they judge, fulfil a covenant when they make one, and show mercy when they are asked for mercy. So whoever of them does not do so, upon him be the curse of Allah Almighty, of the angels and of all people, and no obligatory or voluntary worship of his will be accepted." In another chain of this hadith, Sayyiduna Anas (may Allah be pleased with him) narrates that the Messenger of Allah (peace and blessings be upon him) came to us while we were in the house of a Companion from the Ansar; he (peace and blessings be upon him) took hold of both doorposts and said: "The leaders are from Quraysh. I have a right over you, and they too have a similar right over you, as long as they act with justice and fairness when they judge." Also from Sayyiduna Anas bin Malik (may Allah be pleased with him) it is narrated that the Prophet (peace and blessings be upon him) said: "This Ummah will remain upon goodness as long as it speaks the truth when it speaks, acts with justice when it judges, and shows mercy and kindness when it is asked for mercy." Imam al-Tabarani also recorded this hadith; however, this narration was missed by our Shaykh, al-Hafiz Abu al-Hasan al-Haythami, and he did not mention it in the Zawa'id of the Musnad (Majma' al-Zawa'id).
Hadith Takhrij«إبراهيم بن سعد وأبوه سعد بن إبراهيم: ثقتان (من الحفظ)؛ في سماع سعد من أنس نظر (من الحفظ).» «(4143/1) أخرجه مسند أحمد برقم: 11898، وأخرجه المعجم الأوسط للطبراني برقم: 2118، 2192، 6606» «(4143/2) أخرجه مسند أحمد برقم: 11898، 12489، وأخرجه المعجم الكبير للطبراني برقم: 725، وأخرجه المعجم الأوسط للطبراني برقم: 6606، وأخرجه مجمع الزوائد ومنبع الفوائد برقم: 8988، وأخرجه البحر الزخار المعروف بمسند البزار 10 - 18 برقم: 6181» «(4143/6) أخرجه المعجم الأوسط للطبراني برقم: 799، وأخرجه مجمع الزوائد ومنبع الفوائد برقم: 9000، وأخرجه المطالب العالية بزوائد المسانيد الثمانية برقم: 4184» «(4143/7) أخرجه مسند أحمد برقم: 11898، وأخرجه فتح الباري برقم: 6442، 6720، وأخرجه المعجم الأوسط للطبراني برقم: 2118، 2192، 6606، وأخرجه مجمع الزوائد ومنبع الفوائد برقم: 8978، وأخرجه معرفة السنن والآثار برقم: 5907، 5911، وأخرجه شرح السنة برقم: 102، وأخرجه السنن الصغير للبيهقي برقم: 3136»