A former National Security Agency contractor amassed at least 500 million pages of government records, including top-secret information about military operations, by stealing documents bit by bit over two decades, the Justice Department alleged in a court filing submitted Thursday.

Prosecutors in August arrested and charged Harold “Hal” Martin III,of Glen Burnie, Md., with theft of government property and unauthorized removal or retention of classified documents. The case was kept under seal until earlier this month, when some details became public.

The new filing said the Justice Department would likely charge Mr. Martin with additional crimes, including violating the Espionage Act, an offense that carries much stiffer penalties than the current charges.

Mr. Martin’s attorney, Jim Wyda, declined to comment on the new filing. In the past, he has said that Mr. Martin is a patriotic American who has served his country.