PHILADELPHIA (AP) — A Frenchman who gained access to the cockpit of a plane at Philadelphia International Airport by impersonating an airline employee has been sentenced to time served and will be deported.

Philippe Jeannard, 61, was sentenced Tuesday in federal court after pleading guilty to a fraud count.

Jeannard is from La Rochelle, France. He’s been in custody since March 21, one day after authorities say he unsuccessfully sought a seat upgrade on a Florida-bound flight and then used a fraudulent Air France ID card to gain access to the cockpit. He was found sitting in the jump seat behind the pilot.

His public defender has said he never meant to cause any problems.

A judge said Jeannard won’t be permitted back into the U.S. without written permission from the secretary of Homeland Security.