WASHINGTON (Reuters) - An Iranian man has pleaded guilty to U.S. charges he illegally bought an array of military equipment for Tehran as it prepared for a possible war with the United States, the U.S. Justice Department said on Wednesday.

In a sting operation dating to 2004, U.S. authorities said they negotiated deals to provide the man, Amir Hossein Ardebili, with gyro chip sensors that could be used in missiles and a computer for F-4 fighter aircraft, among other items.

After lengthy negotiations with undercover agents, Ardebili was arrested in October 2007 in an undisclosed central Asian country. He was extradited to the United States in January 2008 and he pleaded guilty in May last year, the Justice Department said.

"The government's investigation and prosecution has put the defendant out of business and removed this threat to our national security," David Weiss, U.S. attorney for Delaware, said in a statement.

Ardebili said he was seeking the military parts because "If the United States come to war ... the government (of Iran) could defen(d) ... because they think the war is coming," according to a document filed with a U.S. court ahead of his December 14 sentencing.

He could face decades in prison.

Ardebili worked for years trying to obtain equipment for Iran, including aircraft parts, Kevlar, night vision devices and communications equipment, according to the court document.

Prosecutors declined to comment on why the case remained under seal for so long. When Ardebili was arrested, authorities seized his laptop computer.

"We did get a number of investigative leads from the laptop and we're pursuing them," said David Hall, a spokesman for the U.S. attorney in Delaware. "The investigation is continuing."

Ardebili pleaded guilty to charges of conspiracy, violating arms export control laws and money laundering. He faces potentially decades in prison.

The United States has been at loggerheads with Iran in recent years over what Washington believes is Tehran's ambition to develop nuclear weapons. Iran has said its nuclear program is for civilian energy use.

Export of certain goods to Iran, particularly sensitive technology that could have a military use, has long been strictly limited.

(Reporting by Jeremy Pelofsky, editing by Cynthia Osterman)