Image copyright AP Image caption The National Security Agency HQ in Fort Meade, Maryland

A National Security Agency contractor has been arrested, accused of taking top secret information, officials say.

Harold Thomas Martin III is charged with theft of government property and unauthorised removal of "highly classified" materials.

The 51-year-old had a top secret national security clearance and faces 10 years in prison.

Mr Martin's lawyer said there was no evidence he had betrayed the US, a country he very much loved.

The Justice Department said he worked for Booz Allen Hamilton, the same contractor that employed NSA leaker Edward Snowden.

Image copyright Twitter

Six of the documents found in Mr Martin's possession were classified as top secret, "meaning that unauthorized disclosure reasonably could be expected to cause exceptionally grave damage to the national security of the US", the Justice Department said.

According to a warrant, Mr Martin was arrested two days after his Glen Burnie, Maryland, home, garage and vehicle were searched on 27 August this year.

The FBI said Mr Martin at first denied taking the documents, but later admitted removing documents and digital files.

James Wyda, Mr Martin's lawyer, told the Baltimore Sun his client has yet to be proven guilty of the charges.

Image copyright Reuters Image caption The Booz Allen Hamilton office building in McLean, Virginia

"There's no evidence that Hal Martin has betrayed his country," Mr Wyda said.

"What we do know is that Hal Martin loves his family and his country. He served this nation honourably in the US Navy and he has devoted his entire life to protecting his country."

Mr Martin faces up to 10 years in prison for the theft of government property, and up to one year for the removal of classified materials.

The New York Times, which broke the story, said Mr Martin was suspected of taking the NSA's "source code" used to hack into the systems of Russia, China, Iran and North Korea.

"A large percentage of the materials recovered from Martin's residence and vehicle bore markings indicating that they were property of the United States and contained highly classified information of the United States," FBI Special Agent Jeremy Bucalo wrote.

"The disclosure of the documents would reveal those sensitive sources, methods, and capabilities."

John Carlin, the Justice Department's top national security official, said the arrest underlined the threat posed by insiders.