A California highway patrol officer has been charged with two felonies, following allegations he stole explicit photos from the iPhones of women he was arresting.

Officer Sean Harrington, who has since resigned, referred to his actions as an ongoing "game" between members of the police department, the San Jose Mercury News reports.

The incidents only came to light after one woman noticed the messages sent from her phone to Harrington's on her iPad. Since she had set Messages to sync between her iPhone and iPad via iCloud, the message showed up on her iPad even though it had been deleted from her phone.

The woman, who is identified in court documents as "Jane Doe No. 1," had reportedly given Harrington her passcode so she could make a phone call after her arrest. An investigation later found that Harrington forwarded five explicit photos of the woman to at least one other officer while she was being processed at the county jail, according to the Mercury News report.

Excerpts of the subsequent conversation between Harrington and another officer detail a conversation in which the men discuss Jane Doe's body, including her breasts and face. "But trust me. She's like a 5 or a 6 at best," Harrington wrote. "Her body is rocking though," the other officer replied.

It appears Harrington's actions were part of an ongoing "scheme" among several officers to share racy photos they found on the phones of women they arrested, according to the the Contra Costa county district attorney's office.

"Harrington said he first learned of this scheme when he was working in the Los Angeles office," Holcombe [senior Contra Costa district attorney inspector] wrote in the affidavit. "Harrington said when he was assigned to the Dublin office, he learned from other officers that they would access the cell phones of female arrestees and look for nude photographs of them. Harrington said if photographs were located, the officers would then text the photographs to other sworn members of the office, and, to non-CHP individuals. Harrington described this scheme as a game."

Despite Harrington's statements to the contrary, the California Highway Patrol initially maintained that the incidents were limited to Dublin and not an issue elsewhere in the state. But a Contra Costa Times report details several such incidents across the country, going back as far as 2005. The CHP later acknowledged a similar incident involving two officers in Southern California.

In one 2011 case — also in Northern California — an investigation found that a female Morgan Hill police officer posted an explicit photo found on a woman's phone to her Facebook page, following an arrest. That officer was later demoted and another officer involved in the incident was fired. The city later reached a $75,000 settlement with the woman but no criminal charges were brought.

In another incident in 2005, a Houston police officer saved nude photos of a woman arrested for a DUI and shared them with other police officers and lawyers at a courthouse. He was never charged, the woman's attorney said, because in 2005 Texas did not have laws regarding photos taken on cell phones.

Regarding the multiple incidents detailed in that report, Harrington is the only police officer to be criminally charged for stealing photos. Though the woman's attorneys have objected that other officers involved were not charged, according to the Mercury News, there is an internal probe into the incident underway.

Ex-CHP officer Sean Harrington surrenders at jail. Lawyer says officer thought stealing semi-nude pics was "a joke." pic.twitter.com/Na2HWyzRha — Laura Anthony (@LauraAnthony7) November 4, 2014

The charges come at a time when law enforcement is coming under increasing scrutiny for how it handles information from individuals' phones.

A Virginia court ruled earlier this month that police officers could compel individuals to unlock their smartphones with their fingerprints but not their passcodes, though the Supreme Court has yet to weigh in on the issue. FBI Director James Comey made comments earlier Monday calling for Apple and Google to make it easier for law enforcement to unlock phones.