The Socceroos were 3-1 down when Tomi Juric’s goal was allowed to stand despite a suspected handball after a review by the video assistant referee.
Lars Stindl had put Germany ahead before Celtic’s Tom Rogic equalised.
Julian Draxler’s penalty made it 2-1 after Leon Goretzka was fouled before Goretzka got the third.
Germany were denied a fourth goal in Russia when Timo Werner hit the post.
Joachim Low has named seven uncapped players in his Confederations Cup squad after resting experienced keeper Manuel Neuer, Arsenal midfielder Mesut Ozil, defender Mats Hummels and forward Thomas Muller.
Germany’s next Group B game is against Chile, who beat Cameroon 2-0 on Sunday, on Thursday (19:00 BST) in Kazan.
Australia face Cameroon on Thursday (16:00 BST) in St Petersburg.
- Russia, qualify as 2018 World Cup hosts
- New Zealand, 2016 OFC Nations Cup winners
- Portugal, Euro 2016 winners
- Mexico, 2015 Concacaf Cup winners
- Cameroon, 2017 Africa Cup of Nations winners
- Chile, 2015 Copa America winners
- Australia, 2015 Asian Cup winners
- Germany, 2014 World Cup winners