Gen. James Cartwright
Retired Marine Gen. James Cartwright, leaves US District Court, October 17, 2016 in Washington, DC. Cartwright pleaded guilty to making false statements during a federal investigation Mark Wilson/Getty Images

A retired US military four-star general has pleaded guilty to making false statements to the FBI during an investigation into the leak of top secret information about a government-sanctioned cyberattack on an Iranian nuclear facility.

James Cartwright, 67, of Gainesville, Virginia, is a retired US Marine Corps general who served as the vice chairman of the Joint Chiefs of Staff between 2007 and 2011, and as commander of the US Strategic Command from 2004 to 2007.

According to the Department of Justice (DoJ), Cartwright – between January and June 2012 – disclosed classified information about the now-infamous Stuxnet computer worm to two reporters, New York Times' David Sanger and then-Newsweek journalist Daniel Klaidman, without authorisation.

While the names of the published articles and books using the leaked information were left unnamed, Sanger previously wrote a book called Confront and Conceal about Stuxnet – a sophisticated exploit developed by US and Israeli intelligence to disrupt centrifuges the Iranians were using to enrich uranium.

After retiring on 1 September 2011, the filings outlined how Cartwright was allowed to maintain his top secret security clearance. It allowed him to engage in "consulting and private employment", which included work with classified US government contracts.

However, the DoJ revealed that after leaving the military Cartwright signed a non-disclosure agreement including warnings "that unauthorised disclosure... by me could cause damage or irreparable injury to the United States or could be used to advantage by a foreign nation."

When FBI agents interviewed Cartwright on 2 November 2012, he reportedly gave false information, denying handing over the classified information and claiming he was not the source of any of the quotes or statements found in Sanger's book. However, upon investigation, the FBI found otherwise.

"We conducted a thorough and independent investigation including collecting tens of thousands of documents through subpoenas, search warrants and document requests, and interviewing scores of current and former government employees," said US attorney Rod Rosenstein in a statement.

"The evidence showed that General Cartwright disclosed classified information without authorisation to two reporters and lied to federal investigators," he added. "As a result, he stands convicted of a federal felony offence and faces a potential prison sentence."

The offence, which relates to lying to investigators and not to talking to the press, carries a maximum of five years in prison. Cartwright's attorney, however, told the judge that the government had agreed on a recommended sentence of no more than six months.

Paul M Abbate, assistant director in charge of the FBI's Washington Field Office, said: "General Cartwright admitted to making false statements to the FBI concerning multiple unauthorised disclosures of classified information that he made to reporters. This was a careful, rigorous, and thorough multi-year investigation by special agents."

After pleading guilty to attempting to mislead the FBI probe, Cartwright said: "I knew I was not the source of the story, and I didn't want to be blamed for the leak. My only goal in talking to the reporters was to protect American interests and lives."

Cartwright's sentencing will be determined by US district judge Richard Leon and has been scheduled for 17 January 2017, the DoJ said.