Sayyiduna Shaddad bin Aws (may Allah be pleased with him) narrated that the Messenger of Allah (peace and blessings be upon him) used to teach us to say in our prayer: "O Allah, I ask You for steadfastness in the matter (of religion), and I ask You for firm resolve upon right guidance" - and the narrator went on to mention a hadith like it.
Hadith Referenceالمعجم الكبير للطبراني / باب الشين / 7147