He reported that the Messenger of Allah ﷺ entered the mosque and came upon a man who had finished his prayer and was reciting the tashahhud, saying, "O Allah, I ask You by Allah, the One, the Unique, the Eternal Refuge, who neither begets nor is begotten, and to whom none is comparable, that You forgive me my sins, for You are the Forgiving, the Merciful."The Prophet of Allah ﷺ said, "He has been forgiven, he has been forgiven, he has been forgiven," three times.
حدثنا عبد الصمد حدثني أبي حدثنا حسين يعني المعلم عن ابن بريدة حدثني حنظلة بن علي أن
حدثه أن رسول الله ﷺ دخل المسجد فإذا هو برجل قد قضى صلاته وهو يتشهد وهو يقول اللهم إني أسألك بالله الواحد الأحد الصمد الذي لم يلد ولم يولد ولم يكن له كفوا أحد أن تغفر لي ذنوبي إنك أنت الغفور الرحيم قال فقال نبي الله ﷺ قد غفر له قد غفر له قد غفر له ثلاث مرات
Its isnad is sahih. Ibn Burayda is Abdullah bin Burayda bin Hasib Aslami, the judge of Marw. He is trustworthy, and his hadith is accepted by all. Similarly, Hanzala bin Ali bin Asqa Aslami. The hadith was narrated by Abu Dawud, 1/258, no. 985, in the book of Prayer, chapter on what is said during the tashahhud, and by Ibn Majah, 1/1267, no. 3857, and by Hakim, 1/267, with Dhahabi agreeing with him.