Sahih Muslim , Book 31, Hadith 6116 (USC-MSA) ⓘ
Abu Huraira reported Allah's Messenger as saying: To the tribe of Aslam Allah has granted safety and to the tribe of Ghifar Allah has granted pardon. Verily it is not I that say this, but (it is) Allah the Exalted and Glorious. (who) says this.
وَحَدَّثَنِي حُسَيْنُ بْنُ حُرَيْثٍ، حَدَّثَنَا الْفَضْلُ بْنُ مُوسَى، عَنْ خُثَيْمِ بْنِ عِرَاكٍ، عَنْ أَبِيهِ، عَنْ أَبِي هُرَيْرَةَ، أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم قَالَ " أَسْلَمُ سَالَمَهَا اللَّهُ وَغِفَارُ غَفَرَ اللَّهُ لَهَا أَمَا إِنِّي لَمْ أَقُلْهَا وَلَكِنْ قَالَهَا اللَّهُ عَزَّ وَجَلَّ " .
also referenced under: Book 44, Hadith 262 (In-Book) & Hadith 2516 (Reference)