It is narrated from Sayyiduna Abu al-Darda' (may Allah be pleased with him) that he used to say: "Indeed, when I enter the mosque, I say (presenting the gift of salam to the Prophet (peace and blessings be upon him)): 'As-salamu 'alayka ya Rasul Allah' (Peace be upon you, O Messenger of Allah)."
This narration is mawquf, and all its narrators are narrators of Sahih al-Bukhari and Muslim; however, its chain is munqati' (broken).
Hadith Referenceالمطالب العالية بزوائد المسانيد الثمانية / كتاب الصلاة / 375
Hadith Gradingمحدثین:إسناده صحيح، منقطع، موقوف
Hadith Takhrij«حکم الحدیث المطالب العالیہ محققاً تنسیق د. سعد بن ناصر بن عبد العزيز الشَّثري- مکتبہ شاملہ :قال ابن حجر: مَوْقُوفٌ ، وَرِجَالُهُ رِجَالُ الصَّحِيحِ ، لَكِنَّهُ مُنْقَطِعٌ . » «انفرد به المصنف من هذا الطريق»
It is narrated from several narrators that when the Prophet (peace and blessings be upon him) went out to the mosque, he would supplicate: "'Allahumma ihfazni min al-shaytan al-rajim' (O Allah, protect me from the accursed Satan)."
Because the names of the narrators in its chain are not stated explicitly ("several"), this narration is munqati' (broken); however, its meaning is supported by other sahih hadith.
Hadith Referenceالمطالب العالية بزوائد المسانيد الثمانية / كتاب الصلاة / 376
Hadith Gradingمحدثین:إسناده منقطع
Hadith Takhrij«حکم الحدیث المطالب العالیہ محققاً تنسیق د. سعد بن ناصر بن عبد العزيز الشَّثري- مکتبہ شاملہ :منقطع » «انفرد به المصنف من هذا الطريق»
It is narrated from Sayyiduna Abdullah bin Salam (may Allah be pleased with him) that "whenever he entered the mosque, he would send salam to the Prophet (peace and blessings be upon him) and then supplicate: 'Allahumma iftah li abwaba rahmatik' (O Allah, open for me the gates of Your mercy); and when he came out of the mosque, he would send blessings upon the Prophet (peace and blessings be upon him) and seek refuge with Allah Almighty from the evil of the accursed Satan."
This narration is mawquf, and there is a break (inqita') in its chain.
Hadith Referenceالمطالب العالية بزوائد المسانيد الثمانية / كتاب الصلاة / 377
Hadith Gradingمحدثین:إسناده موقوف
Hadith Takhrij«حکم الحدیث المطالب العالیہ محققاً تنسیق د. سعد بن ناصر بن عبد العزيز الشَّثري- مکتبہ شاملہ :قال ابن حجر: مَوْقُوفٌ ، وَفِيهِ انْقِطَاعٌ . » «أورده ابن حجر فى "المطالب العالية"، 377، وأخرجه ابن أبى شيبة فى «مصنفه» برقم: 3435، 30387»
It is narrated from Sayyiduna Ali (may Allah be pleased with him) that when the Prophet (peace and blessings be upon him) entered the mosque, he would supplicate: "'Allahumma iftah li abwaba rahmatik' (O Allah, open for me the gates of Your mercy)." And when he came out of the mosque, he would say: "'Allahumma iftah li abwaba fadlik' (O Allah, open for me the gates of Your bounty and grace)."
In the chain of this narration, Layth bin Abi Sulaym and other narrators contradicted Salih bin Musa; according to them, Abdullah bin al-Hasan narrated it from his mother Fatimah bint al-Husayn, and she from her grandmother Sayyidah Fatimah, the daughter of the Messenger of Allah (peace and blessings be upon him).
Hadith Referenceالمطالب العالية بزوائد المسانيد الثمانية / كتاب الصلاة / 378
Hadith Gradingمحدثین:إسناده منقطع، موقوف
Hadith Takhrij«حکم الحدیث المطالب العالیہ محققاً تنسیق د. سعد بن ناصر بن عبد العزيز الشَّثري- مکتبہ شاملہ :موقوف، إسناده منقطع. » «أخرجه مجمع الزوائد ومنبع الفوائد برقم: 2096»