Ali Akbar Javanfekr is one of several high-level aides to Ahmadinejad targeted by hard-line rivals who accuse the president of being in the grip of a "deviant current" of advisers seeking to undermine the role of preachers in the establishment.

The high-level feuding coincides with increasing international pressure on Iran over its disputed nuclear program and preparations for a March 2 parliamentary election that, in the absence of a viable opposition, will largely be a contest between hard-line conservative factions.

The Mashreghnews website report did not spell out how or when Javanfekr, who is managing director of the official Islamic Republic News Agency (IRNA) and media adviser to Ahmadinejad, allegedly insulted Khamenei.

Javanfekr's lawyer later confirmed the sentence, according to students news agency ISNA. Javanfekr has 20 days to appeal.

"Javanfekr also has been stripped of membership of political parties, groups, associations and media activities for five years," Mashreghnews reported.

The semi-official Fars news agency said two other people closely associated with the "deviant current" had been convicted of espionage and economic corruption and would be punished with jail terms, fines and lashings.