Oliver Neuville, Michael Ballack, Lucas Podolski and Tim Borowski scored for Germany while Arsenal keeper Lehmann denied two penalties from Roberto Ayala and Esteban Cambiasso.
Ayala put Argentina ahead shortly after the re-start before Miroslav Klose equalized for the hosts ten minutes from time.
Germany will face the winners from Italy and Ukraine, who play later on Friday, in the semi-final of the World Cup.
Both teams struggled to set the rhythm in the midfield but there was nothing serious except when Ballack escaped his marker in the 16th minute and headed Bernd Schneider's cross just wide.
Germany defended in numbers and Argentina, despite their clear possession, failed to impose any real threat until star defender Ayala stepped up to give his side the lead.
In the 49th minute, Ayala towered to meet Juan Riquelme's corner-kick with a diving downward header that nipped between Lehmann and left-back Philip Lahm who was guarding the near post.
The hosts controlled the pace after the goal and Argentina resorted to defense as manager Jose Pekerman fielded Esteban Cambiasso for Riquelme.
But Germany's top scorer Klose had yet to say the final word as he headed home in the 80th minute after latching on to Borowski's header to level the score and take his tally in the tournament to five goals.
Fabricio Coloccini almost restored the lead in the extra time when he lobbed the ball from the midfield past the advancing Lehmann but his effort hit the woodwork.