LOS ANGELES (AP) — A former U.S. Customs and Border Protection watch commander in Southern California has pleaded guilty to illegal gun-selling and unlawfully possessing more than 40 machine guns.

Wei Xu acknowledged in a plea agreement Wednesday that he sold at least 99 guns without required licenses between the late 1990s and his Feb. 5 arrest.

Xu said he exploited his status as a law enforcement officer at the Long Beach seaport to buy and transfer handguns.

He also pleaded guilty to tax fraud and lying to his employers about his Chinese business partners in order to keep his security clearance.

ADVERTISEMENT

Authorities say they found more than 250 unregistered guns at his home, including the machine guns.

Xu faces up to 25 years in prison when he’s sentenced in January.