Reza Ghoochannejad's winner allowed Iran to beat South Korea 1-0 and top Group A with both countries qualifying.
The result meant South Korea stayed ahead of Uzbekistan on goal difference.
Uzbekistan's 5-1 victory over Qatar moved them to within one goal of South Korea, but the result was not enough to overtake them.Earlier, substitute Josh Kennedy's header with six minutes remaining was enough to book Australia's fourth appearance at the World Cup.
Kennedy, who had replaced Everton's Tim Cahill on 77 minutes, rose unchallenged to head Mark Bresciano's cross beyond goalkeeper Noor Sabri.
Japan had already won Asian Group B to qualify when they drew 1-1 with Australia on 4 June.
With Oman not kicking off against Jordan until after the end of the match in Sydney, the Socceroos knew that a point would ensure qualification for the tournament in Brazil, which starts on 12 June 2014.
Cahill had failed to hit the target from three chances and looked unhappy when replaced with Kennedy by Socceroos coach Holger Osiek.
But the striker, who plays for Nagoya Grampus in Japan's J League, settled the nerves of the crowd of 80,000 to send his country through to their fourth World Cup finals.