A former Yahoo software engineer pleaded guilty in federal court Monday to hacking into thousands of Yahoo users' personal accounts, primarily in search of sexual images and videos, according to the U.S. Department of Justice. CBS San Francisco reports the plea was made public by U.S. Attorney David. L Anderson along with FBI Special Agent in Charge John F. Bennett.

Reyes Daniel Ruiz, 34, of Tracy, California, admitted to using his access at work to hack into about 6,000 Yahoo accounts. Ruiz apparently cracked user passwords and accessed internal Yahoo systems to gain access.

He admitted to targeting the accounts of younger women, including work colleagues and friends from his personal life. Ruiz then made copies of images and videos he took from the compromised accounts and stored the data in his home network.

Get Breaking News Delivered to Your Inbox

Ruiz said after he had access to users' Yahoo accounts, he then compromised their iCloud, Facebook, Gmail, DropBox and other online accounts "in search of more private images and videos," officials said.

After his suspicious activity was observed by Yahoo, Ruiz admitted to destroying the computer and hard drive on which he stored the stolen images and videos.

He was indicted by a federal grand jury on April 4, 2019 on charges of computer intrusion and intercepting a wire communication. He pleaded guilty in federal court in San Jose on the computer intrusion charge under a plea agreement.

Ruiz is on release on the conditions of an unsecured $200,000 bond and is due back in court in February 2020. He is facing a maximum of five years in prison and a $250,000 fine plus restitution.