Abu Ayub reported,

I heard the Messenger of Allah ﷺ say, "No prophet was ever sent, nor any successor who came after, except that he had two close circles of advisors. One circle commands him to do good and forbids him from evil, while the other spares no effort in corrupting him. Whoever is protected from the evil circle has truly been protected."

Azami 7704

Sahih

عن أبي أيوب أنه قال

سمعت رسول الله ﷺ يقول: ما بعث من نبي ولا كان بعده من خليفة إلا وله بطانتان: بطانة تأمره بالمعروف وتنهاه عن المنكر، وبطانة لا تألوه خبالا، فمن وقي بطانة السوء فقد وقي.

الأعظمي 7704صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Leadership
Section
Encouragement to keep righteous companions
Numbering
Jami al-Kamil 7704 (2nd edition)
Azami 7704