Sayyiduna Abdullah bin Mas'ud (may Allah be pleased with him) said: When we prayed behind the Messenger of Allah (peace and blessings be upon him), we would say at the time of the salam: Peace be upon Allah before His servants, peace be upon Jibril and Mika'il (peace be upon them), peace be upon so-and-so, peace be upon so-and-so. One day the Messenger of Allah (peace and blessings be upon him) turned towards us and said: "Allah Almighty is Himself al-Salam (the Source of Peace). When one of you prays, let him say: 'At-tahiyyatu lillahi was-salawatu wat-tayyibat, as-salamu alayka ayyuhan-Nabiyyu wa rahmatullahi wa barakatuh, as-salamu alayna wa ala ibadillahis-salihin' (All acts of worship, prayers and glorifications are for Allah; peace be upon you, O Prophet, and the mercy of Allah and His blessings; peace be upon us and upon all the righteous servants of Allah). When you say these words, your greeting will reach every righteous servant of Allah wherever he is in the heavens and the earth. 'Ashhadu an la ilaha illallah wa ashhadu anna Muhammadan abduhu wa rasuluh' (I bear witness that there is no god but Allah, and I bear witness that Muhammad (peace and blessings be upon him) is the servant of Allah and His Messenger)."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2818