The defending champions had goalkeeper Sherif Ekrami to thank for saving a decisive penalty from defender Mbuyu Twite.
A tough night at Max Stadium saw Sayed Moawad score the only goal in the 71st minute to make it 1-1 on aggregate.
After long spells of one-way traffic, the Tanzanians managed to take the game to penalties, where they almost claimed a shock win.
Goalscorer Moawad saw his penalty saved but Ekrami managed to thwart one in return, only for captain Hossam Ashour to be denied by goalkeeper Deo Munish.
Striker Said Bahanuzi had the chance to settle it, but completely missed the target to level it again.
Defender Mohamed Naguin made no mistake as Egypt number one Ekrami made the crucial stop to deny the Tanzanians.
VIDEOS
Moawad hits a volley after Amr Gamal's effort was blocked.
Penalties