Muhammad ibn Abd al-Rahman al-Gashtuli al-Jurjuri al-Azhari Abu Qabrayn (Arabic: محمد بن عبد الرحمن القشطولي الجرجري الأزهري بوقبرين; died in 1793/1794), mostly known as Sidi M'hamed Bou Qobrine (Arabic: سيدي محمد بو قبرين) was a Berber ash'ari 'alim, founder of the Rahmaniyya Sufi order and is one of the seven Patron Saints of Algiers.
Muhammad was born to the Berber Ayt Smail tribe of the Gashtula tribal confederation in the Djurdjura, Kabylie.
It was in this madrasa that he was initiated to the Khalwatiyya order under his teacher Muhammad ibn Salim al-Hafnawi.
Under his teacher's orders, Muhammad started propagating the tariqa to India and the Sudan.
After thirty years, he returned to Algeria, where he started preaching it among his people and founded a zawiya in his natal village.