Two former foster children who said they were sexually abused by their foster care provider years ago got justice without going to court Monday.

On the day the jury was to be selected for his trial in St. Paul, Joseph L. Larson surprised prosecutors by pleading guilty to two counts of felony criminal sexual conduct. He will receive a minimum 12-year prison sentence; a judge could go as high as 17 years.

Larson, 34, submitted an Alford plea, in which he doesn't admit the criminal act and asserts innocence. Under the plea, a defendant acknowledges that there is sufficient evidence for the prosecution to gain a conviction.

As part of the plea deal, felony child pornography possession charges filed in Anoka County will be dismissed. Sentencing will be June 28.

Ramsey County attorney John Choi said his office and the victims were pleased by the outcome. He said that because Larson agreed to a plea, it spares the victims the need to testify at a trial.

Larson's attorney, Katie Rindfleisch, declined to comment. She had recently told the Star Tribune that "Joe has never and would never hurt a child." She planned to call several of his former foster children to share how Larson saved their lives.

Allegations of a foster parent sexually abusing the children entrusted to their care are very rare, prosecutors said.

One of the former foster children, now 17, was in Larson's care from 2002 to 2005; the other, now 23, was with him for three months in 2003.

Before he was charged last summer, Larson was investigated twice by a child pornography task force but not charged. He had his foster care license closed in 2006 after one of the youths made an allegation against him, according to court documents. He later had a second license revoked because he didn't disclose information about his previous license and the investigations.

Larson became a licensed foster parent through a private agency, PATH Minnesota Inc., in Monticello in 2002. He cared for four children, including two brothers, with the agency. In 2004, a state task force received a report from U.S. Immigration and Customs Enforcement about information discovered during an Internet child pornography investigation. Investigators found that credit cards issued to Larson had been used to buy access to child pornography websites in 2002 and 2003, court documents said.

Two officers assigned to the case couldn't gather enough information for a warrant to search Larson's computer. In 2006, officers again investigated Larson, but he told them he wouldn't consent to a search of his computer because it contained private information about foster children, according to a police report.

In February 2010, police were again alerted when the youth who is now 17 told a social worker about sex abuse that allegedly occurred during his time in Larson's care, according to a criminal complaint filed against Larson. Police subsequently interviewed the 23-year-old, who is not related to the 17-year-old, and Larson was charged in August.

Larson remains out of jail on $30,000 bail he posted last year. He is barred from having any contact with the victims.