Defender Jeitoso scored a late equaliser for Mozambique as they held Group B winners Malawi to a 1-1 draw in their final pool match at the King Zwelithini Stadium on Thursday.
The Flames had already qualified for the quarterfinals before the game, and looked set to keep up their winning run before being pegged back by a late goal from The Mambas.
Namibia finished second in the pool after a comprehensive 3-0 victory over Seychelles, ending a promising tournament for them with a largely home-based squad devoid of the major stars.
Mozambique are third with two points, and Seychelles end with one, with the former especially disappointed after they had targeted a knockout place from the pool.
Malawi took the lead after a goalkeeping error from Victor between the sticks for Mozambique when he dropped the ball after what looked a routine catch.
Hassan Kajoke reacted quickest to the loose ball and scored from barely a metre out to net a sixth goal of the competition for The Flames.
Mozambique should have equalised when Witi’s trickery on the right flank produced a delicious cross that was headed wide by Nilton when it seemed easier to score.
There were chances at either end, but in the case of Malawi too often the final ball failed to find a Flames player.
The Mambas finally got their goal when defender Jeitoso ghosted into the box from a corner kick and provided an excellent leap to head into the back of the net.
Namibia eased to their success, set on their way by two first-half goals from Issaskar Gurirab.
They were always too strong for Seychelles and continued to rain in shots on goal, finally being rewarded with a third goal through Sadney Urikhob.
The quarterfinal action will kick-off on Saturday when Lesotho take on East African guest nation Uganda (kick-off 15h00 local; 13h00 GMT), who will be headed to the 2019 Africa Cup of Nations next month.
The Ugandans have brought a home-based squad, but one packed with potential and players fighting to gain a spot in the squad to go to Egypt.
These two sides met in the Nations Cup qualifiers last October, with Uganda claiming 3-0 (home) and 2-0 (away) victories, presenting The Crocodiles with a chance for some revenge.
The second quarterfinal sees defending champions Zimbabwe take on Comoros Islands (kick-off 17h30 local; 15h30 GMT), with the latter in the knockout stages for the first time in their history.
Zimbabwe have won the previous two instalments of the COSAFA Cup, extending their overall record to six tournament victories, and have brought a strong squad again this year.
They last met in the African Nations Championship qualifiers in 2015 when Zimbabwe claimed a 2-0 home win and drew 0-0 away.
Mozambique 1 (Jeituso 90’) Malawi 1 (Kajoke 32’)
Namibia 3 (Gurirab 19’, 26’, Urikhob 66’) Seychelles 0
Lesotho vs Uganda (KO 15h00; 13h00 GMT) – Princess Magogo Stadium
Zimbabwe vs Comoros (KO 17h30; 15h30 GMT) – Princess Magogo Stadium
Group A P W D L GF GA Pts
Comoros (Q) 2 1 1 0 4 3 4
Eswatini 2 0 2 0 4 4 2
Mauritius 2 0 1 1 3 4 1
Group B P W D L GF GA Pts
Malawi (Q) 3 2 1 0 6 2 7
Namibia 3 2 0 1 6 3 6
Mozambique 3 0 2 1 2 3 2
Seychelles 3 0 1 2 0 6 1
Matches Played: 9
Goals scored: 25
Biggest victory: Malawi 3 Seychelles 0 (Group B, May 26)
Most goals in a game: 4 – Eswatini 2 Mauritius 2 (Group A, May 25); Eswatini 2 Comoros 2 (Group A, May 27)
3 goals – Ashley Nazira (Mauritius)
2 – Felix Badenhorst (Eswatini), Issaskar Gurirab (Namibia), Youssouf Ibroihim (Comoros), Gabadinho Mhango (Malawi), Gerald Phiri Jnr (Malawi)
1 – Charles Hambira (Namibia),Soulaimana Ibouniyamine (Comoros), Jeituso (Mozambique), Hassan Kajoke (Malawi), Absalom Iimbondi (Namibia), Joslin Kamatuka (Namibia), Siboniso Mamba (Eswatini), Richard Mbulu (Malawi), Sabelo Ndzinisa (Eswatini), Boina Bacar Raidou (Comoros), Sadney Urikhob (Namibia), Witi (Mozambique)