Image copyright AP Image caption New York Times reporter James Risen refused to reveal his sources

A former CIA officer has been convicted of leaking classified details of a US operation against Iran to a reporter.

Jeffrey Sterling denied the leak but was found guilty in a Virginia court of all nine counts he faced.

New York Times reporter James Risen was the recipient of what former Secretary of State Condoleezza Rice testified was one of the most closely held secrets.

But he was not called to give evidence because he said he would never reveal his sources, even if jailed.

The US operation to thwart Iran's nuclear plans involved involved using a CIA agent nicknamed Merlin to pass on erroneous nuclear blueprints to Iran.

Mr Risen's book State of War described this plan as botched and counter-productive because they could have armed Iran with nuclear expertise.

Defence lawyers admitted the journalist and former agent had a relationship, laid bare in phone calls and emails, but they argued there was no evidence the two men discussed anything classified.

Sterling will be sentenced in April.

Analysis: Tara McKelvey, White House reporter, BBC News

This is the first time in 30 years a jury has convicted a former official of leaking classified information - and shows the seriousness of Sterling's crime as well as the US justice department's aggressive approach towards leaks under US President Barack Obama.

In previous leak cases, such as one involving a former CIA officer named John Kiriakou, the accused have reached plea agreements.

Sterling's case underscores the hard line Mr Obama has taken against leaks. He has pursued more leak cases than George W Bush and all other presidents combined.

"The prosecution reflects the political climate," says Steven Aftergood, director of the Federation of American Scientists' Project on Government Secrecy, referring to the Sterling case. "It shouldn't, but it does."

In 1985 a jury convicted Samuel Loring Morison, a former naval intelligence analyst, of disclosing classified information to the media but he was later pardoned by President Bill Clinton.