The Gabonese referee ruled that Abdullahi Shehu fouled Brahimi as he moved into the box in Constantine, but big-screen replays suggested otherwise.
Nigeria went ahead on 62 minutes when John Ogu pounced on a weak clearance by Aissa Mandi and rifled the ball past Faouzi Chaouchi into the roof of the net.
A heated second half that threatened to get out of control at times gave the crowd some cheer after a woeful opening 45 minutes in which Algeria did not have a shot on target.
The final-round qualifier marked the start of a third spell as Algeria coach for 1987 African Footballer of the Year Rabah Madjer.
He would have been disappointed with some of the chances wasted by the "Desert Foxes" with Mandi and Islam Slimani missing second-half "sitters".
The stalemate meant Nigeria finished unbeaten and Algeria winless in the "group of death", which will be completed Saturday when second-place Zambia host Cameroon in Ndola.
Nigeria finished with 14 points, Zambia have seven, Cameroon six, and Algeria just two from a bitterly disappointing campaign after reaching the
last-16 of the 2014 World Cup.
Bosnian coach Vahid Halilhodzic quit soon after the extra-time loss to eventual champions Germany in Brazil, complaining of continuous media criticism.
Madjer is the fifth coach to be put in full-time charge since after Frenchman Christian Gourcoff, Serb Milovan Rajevac, Belgian Georges Leekens and Spaniard Lucas Alcaraz.
Algerian Nabil Neghiz had a short spell as caretaker coach of a team that has plummeted from first to 13th in the FIFA Africa rankings.