<P> He attempts to leave the train but is stopped by a young woman who hands him another envelope with Michael's wife's wedding ring, and tells him it's a warning . Michael attempts to call his wife but with no response . Michael attempts to warn a fellow passenger of what is going on by writing on his newspaper . Michael leaves a voicemail describing the situation to former partner, Murphy, and then receives a call from Joanna, threatening him and his family . She tells him to look outside, where he sees the passenger he gave the newspaper to deliberately pushed in front of a bus . Joanna then points him to a GPS tracker in his jacket and instructs he plant it on Prynne . </P> <P> Michael gives a fake report of suspicious behavior to a conductor, who announces he plans to search a woman's bag . A man immediately leaves the car and Michael follows him, at which point he attacks Michael . They fight and Michael plants the GPS tracker on him . Murphy calls back and informs him that Prynne is a key witness in a supposed suicide case of a man at the city planner's office, Enrique Mendez, leading Michael to realize that Prynne will be killed and that Michael is being set up . </P> <P> In a deserted car, Michael discovers the body of the man he planted the GPS tracker on and a badge revealing he was an FBI agent . Sabotaging the air conditioning in the train except for the last car, Michael forces all of the remaining passengers into the last car . He realizes another passenger, a musician, killed the FBI agent; he also received the same deal for $100,000, but with instructions to kill Prynne . Michael and the musician fight, at which point the musician is thrown from the train and killed . The real "Prynne" is revealed to be a young girl named Sofia, who is holding incriminating information on powerful people and was to go into witness protection at the final stop of the train . Michael asks Sofia why she did not go to the police . She reveals that it was the police who killed Enrique, who was Sofia's cousin . </P> <P> Joanna calls Michael and tries to convince him to kill Sofia for the sake of his family, but Michael refuses . Joanna activates the fail - safe plan and derails the train in order to kill everyone aboard . Michael manages to save all of the passengers by unhooking the final car from the rest of the train right before a curve . </P>

Who killed the fbi agent in the commuter