A 35-year-old Stockton man pleaded guilty Monday to two federal charges related to a scheme to defraud companies out of unfulfilled invoices, the U.S. Attorney’s Office in Sacramento said.

Hector Perez entered the plea to charges of wire fraud and aggravated identity theft in the operation. Prosecutors say he worked with his brother Flavio, 30, in the ploy that netted them $2 million.

Flavio Perez is awaiting trial on the charges against him.

The fraudulent operation sheds light on a legitimate and little-known corner of the business world. “Invoice factoring,” as it’s called, involves businesses that buy unpaid customer invoices from companies that want immediate payment rather than trying to take the time to collect the debts. The companies selling the invoices get immediate payment. The businesses that buy them make a profit after the customers who have been billed eventually pay up.

The Perez brothers, however, cheated by creating fake corporate entities that posed as legitimate businesses and sold manufactured invoices, federal prosecutors said.

The pair profited by selling the fraudulent invoices to at least four companies, according to court documents. The companies that fell victim to the scheme either never received payment on the fake invoices or were shortchanged.

The crimes took place between May 2018 and November 2020, prosecutors said.

Hector Perez faces a maximum penalty of 20 years in prison and a $250,000 fine for the wire fraud counts, and a mandatory consecutive two years in prison for the aggravated identity theft count. He is due to be sentenced Aug. 24.

Flavio Perez is next due in court July 13. If convicted, he faces the same maximum penalty as his brother.