Ten-man Japan squeezed past Syria 2-1 in Asian Cup group B match on Thursday to be on track for the knockout rounds.
Captain Makoto Hasebe opened the scoring for the three-time champions in the 35th minute but Syria pulled one back from a penalty controversially awarded against goalkeeper Eiji Kawashima on 76 minutes.
Kawashima was adjudged to have brought down Sanharib Malki despite the player being flagged offside.
Japanese players and team officials protested loudly but Iranian referee Torky Mohsen gave a penalty and dismissed the goalkeeper in chaotic scenes.
Shusaku Nishikawa came on as a replacement. Firas Al Khatib calmly converted the spot kick.
Down to 10 men, Japan World Cup hero Keisuke Honda slotted in the winner from another penalty six minutes later.
Japan needed the three points to be alive for the knockout stage after salvaging a 1-1 draw with Jordan in their opener.
Jordan beat Saudi Arabia 1-0 in the earlier Group B game to put the Gulf giants out of contention, with Japan and Jordan now on four points, Syria on three and the Saudis down and out on zero.