A US lawyer could be jailed for up to 10 years for helping to upload porn films to file-sharing sites and then sue people who downloaded them.
Paul Hansmeier has pleaded guilty to charges of wire fraud and money laundering for his part in the Prenda Law piracy scheme.
Prenda is believed to have made about $3m (£2.3m) from the scheme.
His guilty plea is part of an agreement that will ensure he does not receive a sentence longer than 150 months.
Court documents released on Friday reveal that Hansmeier and colleague John Steele set up Prenda Law in 2010 and initially acted for pornographic film-makers keen to stop their films being pirated online.
The firm took legal action to uncover pirates’ names and addresses and asked them to pay up to $3,000 (£2,700) to avoid legal action over the illegal downloading.
In 2011, the firm started to upload films itself to file-sharing sites and then sue people who took copies.
Later on, it made its own pornographic films and put these on pirate sites so it could gather more cash.
The documents suggest Prenda set up shell companies to gather the “settlement” fees and hide its involvement.
The settlement scheme was uncovered by an investigation into Prenda Law, which saw both Hansmeier and Steele charged with fraud in 2016.
Steele pleaded guilty in early 2017 to seven charges including mail and wire fraud. He also agreed to help prosecutors investigating the case.
Hansmeier was due to be tried on 5 September for his involvement in Prenda but the plea agreement means that trial will not now go ahead. Instead, a judge will decide his sentence.
The agreement will also end investigation into other potential crimes that Hansmeier has been accused of.
It also includes clauses that will see cash gathered by Prenda, and potentially more in damages, returned to the people who paid up.
Hansmeier is currently challenging an earlier legal decision that threw out his call to dismiss all charges against him. If that claim is upheld, the plea agreement will no longer be binding.