A former computer contractor who stole terabytes of data from the US National Security Agency (NSA) has pleaded guilty to taking classified documents.
Harold T Martin amassed documents and disk drives at his home, but is not believed to have sold or shared them.
Mr Martin is reported to have pleaded guilty as part of a sentencing deal struck with the prosecutors.
The deal means some charges have been dropped but also lets prosecutors seek a nine-year jail sentence.
The crime that Mr Martin has pleaded guilty to is one count of wilfully retaining national defence information. In return, prosecutors have dropped 19 separate charges, including spying, levelled in the early stages of the case.
The New York Times said the 50 terabytes of data that Mr Martin hoarded in his Baltimore home could be the biggest breach of classified information in history.
At least six of the documents found in his possession were classified as top secret.
This, said the Justice Department at the time of his arrest, meant that their “unauthorised disclosure could be expected to cause exceptionally grave damage to the national security of the US”.
The vast pile of information was built up over the 20-year period that Mr Martin worked at the NSA and other US federal agencies.
Lawyers for Mr Martin said there was no evidence that he betrayed the United States. In court, they said the hoarding was a result of “mental illness”, not malice or treason.
Mr Martin’s cache of data was uncovered in 2016 as investigators probed the NSA, following a series of damaging leaks by other people.
Information about the activities and capabilities of the NSA was released by whistleblower Edward Snowden and separately by an anonymous hacking group called the Shadow Brokers.
A sentencing hearing to determine the jail term that Mr Martin will serve has been scheduled for July. The two-and-a-half years he will have spent in jail during the case will be deducted from any sentence he serves.
NSA contractor pleads guilty to data theft