A Pennsylvania man has agreed to plead guilty to a felony computer hacking charge after authorities said he illegally accessed private phone and email accounts of celebrities such as Oscar-winning actress Jennifer Lawrence to leak information including nude pictures.

The U.S. attorney for the Central District of California charged Ryan Collins, 36, from Lancaster, Pennsylvania, according to court documents filed on Tuesday.

RELATED: Second PA Supreme Court justice steps down in wake of porngate scandal

Collins signed a plea agreement to plead guilty to a felony violation of the Computer Fraud and Abuse Act. He faces up to five years in federal prison, with a recommended prison term of 18 months and a fine of $250,000.

The case has been transferred from California to the Middle District of Pennsylvania, where Collins is expected to surrender and plead guilty. He will be sentenced at a later date.

While no victims were named in the court documents, Lawrence and other celebrities such as actresses Kirsten Dunst and Gabrielle Union and model Kate Upton addressed the leak and online dissemination of their nude photos in interviews.

Representatives for Lawrence, Dunst, Union and Upton did not return Reuters' requests for comment on Wednesday.

Prosecutors said in court documents that between November 2012 and September 2014, Collins "knowingly, intentionally, and in furtherance of criminal and tortious acts" accessed at least 50 Apple iCloud accounts and about 72 Google Gmail accounts belonging to more than 100 people.

Known as a 'phishing' scam, Collins used fraudulent email disguised to impersonate legitimate security services, such as "email.protection318@icloud.com," and requesting usernames and passwords from the victims, according to prosecutors.

RELATED: Queens men part of New York trio charged in Bitcoin-related cases

By doing so, Collins accessed the iCloud accounts, used for online data storage, for 18 celebrities and downloaded the backed-up data that included nude pictures and videos, court documents said.

It is not the first time a suspected hacker has been charged with leaking celebrity nude photos.

A Florida man was sentenced in 2012 to 10 years in prison for hacking into email accounts of Scarlett Johansson, Mila Kunis and Christina Aguilera to leak private information and nude photographs.