Two Palestinians have been killed in a shootout with police after allegedly attacking a bus in Jerusalem and then opening fire outside the Old City, Israeli police said.

At least one person was critically injured after the men opened fire at a lightrail stop near the New Gate of the Old City as they were being chased by police on Wednesday.