The referee blows his final whistle, Egypt are through to the semi final after securing their first win over Morocco since 1986.
In Morocco's last chance, Boussoufa's curling free kick hits the side netting.
Egypt make their third substitution. Tarek Hamed is replaced with central defender Saad Samir.
Egypt sit back to defend their valuable lead as the referee adds three minutes of stoppage time.
Substitute Kahraba finally scores for Egypt, volleying home from close range after his own header from a corner deflected off teammate Kouka and fell into his path.
GOOOOAAAAAAAAAAAAAAAAAAAL FOR EGYPT!!!
Too many mis-placed passes make it difficult for both sides to create chances.
Egypt's flanks are still exposed, with Moroccan wingers finding no difficulty in whipping in crosses.
Ten minutes remaining, both sides look capable of snatching a win in the dying minutes.
A golden chance spurned by Salah!! Abdallah El-Said's chipped cross finds the Roma man whose left-foot volley is blocked by the keeper with the goal at his mercy. This is a typical free kick maneuver orchestrated by Hector Cuper!
Egypt's Kahraba receives a yellow card for a challenge on Karim El Ahmadi.
Egypt's midfielder Mahmoud Hassan (L) challenges Morocco's midfielder Nabil Dirar
Ahmed Elmohamady is dispossessed on the right but a Moroccan cross is cleared by Ali Gabr. Morocco's pressure is hugely effective.
Morocco go close again! A header from the dangerous Bouhaddouz is deflected off Ahmed Hegazy and narrowly misses the target.
Egypt created a solitary second-half chance which Salah wasted. They are now struggling to mount any threats.
Morocco have the upper hand in aerial challenges.
Karim Hafez is replaced. He makes way for winger Mahmoud Kahraba, with Ahmed Fathi likely to occupy the left flank to stop a wave of Moroccan attacks.
Egypt's left-back Karim Hafez is repeatedly exposed. Morocco make inroads down the right.
Another chance for Morocco! Bouhaddouz somehow miscues a low cross from Nabil Dirar with the goal at his mercy.
The game is a physical duel but Morocco are better in the second half.
Morocco create a chance after chance! Bouhaddouz towers above Ahmed Hegazy to head just wide.
Another chance for Morocco! A long-range shot from M'bark Boussoufa strikes the bar!!
Essam El-Hadary rescues Egypt!! He makes a superb interception to clear a low cross from Nabil Dirar just before it reaches Aziz Bouhaddouz.
Egypt now look much more dangerous.
What a chance for Egypt!! Abdallah El-Said finds Mohamed Salah with a superb overhead kick and the AS Roma man outpaces his challenger to break clear, but his eventual angled volley is thwarted by keeper Munir Mohamedi.
Morocco's Nabil Dirar darts down the right unopposed but his wayward cross goes out for a goal kick.
The second half is underway.
The referee blows his halftime whistle.
Morocco mount pressure in the latter stages of the first half, albeit without creating clear-cut chances.
Egypt make their first substitution, Mohsen makes way for Sporting Braga striker Ahmed Kouka.
It seems that Mohsen will not be allowed to carry on. He will be replaced shortly.
Marwan Mohsen is receiving treatment on the pitch after a challenge with an opponent.
The firstchance for Morocco!! Romain Saïss is found unmarked following a low cross from the right but he fails to get his foot on the ball with the goal at his mercy. The ball then rebounds into his path but his header goes over the bar.
Salah steals possession from a Moroccan full-back but his tame cross is cleared.
Egypt's midfielder Ahmed Elmohamady (L) challenges Morocco's midfielder Karim El Ahmadi.
Too many fouls are committed by Morocco's defenders and midfielders to stifle Egyptian attacks.
Both sides ease off but Egypt are relatively in control.
Romain Saïss' header from the ensuing corner goes high over.
Ahmed Hegazy makes a sliding tackle to clear a right-wing cross. It's a corner for Morocco.
Morocco's passes in the final third are still inaccurate as Egypt's defenders comfortably steal possession.
Egypt have the upper hand in terms of possession and chances created.
Another chance for Egypt!! Ahmed Elmohamady's cross eludes the defence and finds Mahmoud Trezeguet on the left but his angled shot is blocked by the keeper at the near post.
A free kick is awarded for Morocco on the right, but Faycal Fajr's fine cross is cleared by the defence.
Egypt's Tarek Hamed receives a yellow card for reckless challenge on Aziz Bouhaddouz.
At the other end, Morocco's Hamza Mendyl outpaces Elmohamady but his cross goes beyond the reach of the forwards.
The first chance for Egypt! A corner is poorly cleared by the Moroccan defence and the ball falls into the path of Ahmed Elmohamady, whose low shot from inside the area is deflected.
Morocco press Egypt high up the pitch in the early stages.
The pitch's condition still looks bad at Port Gentil!
The match is underway.
Thirty minutes remaining before kick-off, fans have already filled coffee shops to watch the anticipated clash.
Morocco stick to the same line-up which they fielded against Ivory Coast when they won 1-0 in their last group-stage clash.
It's true, injured left-back Mohamed Abdel-Shafi and midfielder Mohamed Elneny are out of the starting line-up. Karim Hafez will make his first appearance, replacing Abdel-Shafi, while versatile midfielder Ahmed Fathi will take Elneny's place alongside Tarek Hamed in the heart of midfield.
If Mohamed Abdel-Shafi, who has been suffering from an injury he picked up in the 1-0 win over Uganda, does not make it, it will be either France-based Karim Hafez or Basel's Omar Gaber who will play as a left-back.
Egypt coach Cuper could be forced to field versatile full-back Ahmed Fathi as a defensive midfielder to play alongside Zamalek's Tarek Hamed.
Local media reported that Egypt and Arsenal midfielder Mohamed Elneny sustained a minor injury during training session and could be sidelined.
Morocco had to do without several regulars after they were ruled out of the tournament through injuries, including Younes Belhanda, Nouredine Amranat and Sofiane Boufal.
Egypt are sweating on the fitness of regular left-back Mohamed Abdel-Shafi, who missed the win over Ghana after picking up an ankle injury against Uganda. In his absence, natural right-back Ahmed Fathi was deployed on the left and he was equally impressive, keeping Ghana's pacy winger Christian Atsu at bay.
"Everyone knows Egypt; they are a very strong team and a great competitor. I faced this team many times and I know them by heart. They have fighting spirit, and when they come to competitions like this one they just come to win." Says Morocco coach Herve Renard.
"Morocco is a very strong and organized team. They are very strong defensively and got many talented players, and I believe they are one of the title favorites. I said many times that all the teams here are strong." Says Egypt coach Hector Cuper ahead of the two sides' game. "We are going to do our best, and I hope we can win and qualify to the semi finals," Cuper added.
Frenchman Renard, who is looking to make history by winning the Nations Cup with three different teams after guiding Zambia and Ivory Coast to the coveted title, has been largely conservative in the group stage as his physical side recovered from an opening defeat by DR Congo to beat Togo and the Ivorians.
Egypt have met Morocco 12 times, drawing 8 matches and losing four. They could not even beat Morocco when they lifted the Nations Cup trophy in 1998 and 2006, losing 1-0 and drawing 0-0 respectively.
Several Egypt players have played down the significance of a decades-old barren run against Morocco, but they are well aware they need to bury the ghost of their North African rivals if they are to reach the African Cup of Nations semis for the first time in seven years.
Stay tuned as match is due to start at 21:00 Cairo time (GMT+2)