Tim Cahill celebrates a goal when he played for the Red Bulls in 2014. (Winslow Townson/USA TODAY Sports)

SYDNEY, Australia — Former Red Bulls midfielder Tim Cahill scored twice, including the game-winner in extratime to lift Australia to a 2-1 victory over Syria in the Asian playoff second leg in World Cup qualifying Tuesday night.

The result lifted the Socceroos to a 3-2 win in the aggregate series after the two teams played to a 1-1 draw in Malaysia last week.

The Aussies will play the fourth-place CONCACAF team — either the United States, Panama or Honduras — in an aggregate goals playoff series from Nov. 6-14.

Those three squads will have their CONCACAF fates decided in three matches Tuesday.

“This is what football is about. You have to write your own script,” Cahill told Fox Sports. “I knew I was going to score. It’s not something your over confident about but you put yourself in the right position, it’s like waiting for a bus.

“I didn’t touch the ball much but I did my job, I kept the defenders back, made rooms for our 10s and in the end delivered. That’s what I have done my whole life and I’ll continue to do it.”

Syria grabbed a 1-0 lead in the fifth minute, taking advantage of a turnover that Al Soma scored.

The 38-year-old Cahill, however, equalized seven minutes later, as he headed a Matthew Leckie feed and scored between two center backs.

The former Red Bull pulled off some late heroics as Aaron Mooy sent a ball to Robbie Kruse down the right wing. Kruse then found a leaping Cahill, who headed the ball home.

“We knew we would tire them out and wait for our chances and in the end we got the goals,” Cahill said. “It’s great to get the result not only for the players but for the manager as well. We’ve been working hard.

“We’re doing it the hard way but its feeling pretty good at the moment.”

Cahill now has 50 international goals.

“I said when he broke the 100 games that he’s a great Australian sportsman, beyond our sport,” Australia head coach Ange Postecoglou said. “He’s got an international record that will stack up against the best in the world, and he keeps doing it.

“I can’t remember the last time he played 90 minutes and he’s gone out there and played 120 minutes. He’s got something about him for sure. You know these games throw up pressure and you’re looking for people who have been through it before and know what it takes … [Cahill] was at the forefront of that.”

Cahill said Australia is ready for its next challenge from a CONCACAF foe.

“It doesn’t matter who we play, now we have to take the next level as a group and to believe in ourselves,” Cahill said. “This four-year journey has been amazing. It’s all down to the boss’ belief.

“We won’t take a step backwards.”