Finally, in 667/8, Maslama himself petitioned Mu'awiya ibn Abi Sufyan, now Caliph, and was appointed governor of Egypt.
Little is known of is tenure, except that he was active in the wars against the Byzantine Empire, sending regular expeditions against them, and rebuilt the Mosque of Amr ibn al-As in Fustat, to which he added minarets.
[1][3] Some sources claim that Maslama was also responsible for the Muslim campaigns in Ifriqiya and the Maghreb in general, although others insist that these areas did not come under his authority until ca.
675; at any rate, he replaced Uqba ibn Nafi, who had been in charge in Ifriqiya until then, with Abu al-Muhajir Dinar in 671 or in 675.
[1] Maslama remained a firm adherent of the Umayyads to the last, and when Mu'awiya died in 680, he immediately recognized his son, Yazid I, as his successor; he reportedly threatened even Amr ibn al-As's son Abd Allah, another Companion and respected hadith scholar, with execution when he objected.