Loyalists of Iran's supreme leader, who is implacably hostile to the West and its drive to curb Tehran's nuclear work, look set to triumph in Iran's parliamentary poll at the expense of President Mahmoud Ahmadinejad in a contest among hardliners.
Supreme Leader Ayatollah Ali Khamenei turned against the man he backed in a disputed presidential vote in 2009 after Ahmadinejad challenged his authority over top government posts.
Ahmadinejad, first elected in 2005, had shown signs of seeking real power for the presidency, which in the Islamic Republic has always played second fiddle to the supreme leader in all state matters such as nuclear and foreign policy.
But Khamenei remains in the driving seat and the outcome of the March 2 election is unlikely alter Iran's defiance of the West over its nuclear programme, despite ever harsher sanctions and the possibility of an eventual military confrontation.
An alliance of clerics, elite Revolutionary Guards and influential bazaar merchants has made sure many pro-Ahmadinejad politicians cannot register to run for the assembly.
Politicians say the Guardian Council, made up of six clerics and six jurists who vet candidates, has barred many Ahmadinejad supporters, forcing him to pick younger political unknowns.
"They had no public link to Ahmadinejad's camp, but the Council was wise enough to spot them and around 45 percent of his supporters have been disqualified," said one official involved in the multi-layered vetting process.
A list of qualified candidates will be announced on Feb. 21.
With bruised reformists not involved, that should translate into a parliamentary majority for Ahmadinejad's foes in a power struggle among Iran's clerical and political conservatives.
Khamenei stymied Ahmadinejad's tentative attempts, early in his presidency, to compromise in a nuclear dispute that has led to a tightening web of sanctions and threats of U.S. or Israeli military action to stop Tehran from acquiring atomic bombs.
Iran says its nuclear programme, begun under the U.S.-backed Shah, is only for peaceful energy and medical purposes.
Dissension among hardliners came to the fore in April when Khamenei reinstated an intelligence minister the president had sacked, thwarting an attempt by Ahmadinejad to install his own man in the ministry, which also vets election candidates.
Since then, lawmakers have threatened to start impeachment proceedings against Ahmadinejad while others have accused him of being in the grip of a "deviant current" of advisers seeking to undermine the role of the clergy in the Islamic establishment.
"Such an attack is impossible without Khamenei's green light," said political analyst Hamid Farahvashian.
CHALLENGING THE CLERGY
Ahmadinejad, an engineer and former Revolutionary Guard officer with no clerical background, has implemented populist policies to build his own power base.
"Ahmadinejad's camp knows that they have lost the votes of core supporters ... because of challenging the role of the clergy," said a former official, who asked not to be named.
"The 10 to 15 million core supporters of the system will vote for the Khamenei camp. Ahmadinejad's camp is after votes of nationalists," he added.
With a corruption scandal lingering over his government, Ahmadinejad, who must step down next year after two terms as president, now looks unlikely to be able to install one of his loyalists in the post, analysts and critics say.
The attacks on Ahmadinejad signal a turnaround from 2009, when Khamenei supported his re-election, which the reformist opposition said was rigged, igniting eight months of violent street unrest, the worst in the Islamic Republic's history.
The government put the uprising down by force, but Arab uprisings since then have revealed that authoritarian states can be vulnerable to popular anger fuelled by economic hardship.
Leading reformists are not taking part in next month's poll, which they say will not be free or fair. Opposition leaders defeated in the 2009 presidential vote, Mirhossein Mousavi and Mehdi Karoubi, have been under house arrest for a year.
The process of vetting candidates, which includes checks on loyalty to Iran's constitution and clerical leadership, is rooted in a theological debate once confined to Shi'ite religious seminaries but now increasingly out in the open.
Hardline supporters of Khamenei accuse Ahmadinejad's camp of pursuing an "Iranian" school of Islam, an ideology which some see as an inappropriate mix of religion and nationalism.
Ahmadinejad accuses his rivals of breaking laws by insulting him and has threatened them with jail. Defaming top officials is a crime punishable by a maximum two-year prison sentence.
Politics in Iran are largely defined by attempts to claim the legacy of the late Ayatollah Ruhollah Khomeini, father of the revolution. Both camps portray themselves as the most capable of defending his commitment to Islam and social justice.
While Khamenei is only Iran's second supreme leader, meant to be a neutral arbiter in political life and ultimate Islamic authority in matters of state, presidents have come and gone.
Khamenei, who survived an assassination attempt in 1981, may hope to secure the presidency for one of his own acolytes: his adviser Ali Akbar Velayati or Foreign Minister Ali Akbar Salehi.
Velayati was foreign minister during the Iran-Iraq war in the 1980s and shares Khamenei's policy views, while Salehi has been a driving force behind Iran's nuclear programme.
Western sanctions aimed at forcing Iran to make nuclear concessions have started to hurt energy and food imports, but many Iranians blame Ahmadinejad's policies for soaring prices.
They say his cuts in food and fuel subsidies, replaced with direct monthly payments of around $38 per person, have fuelled inflation, officially running at around 20 percent, although some economists say it is more like 50 percent.
"Those in towns and villages support Ahmadinejad. They fear that if the rival camp wins, the subsidy cash distribution will be stopped," said one analyst who declined to be named.
Ahmadinejad has also been tainted by Iran's biggest fraud scandal, made public with Khamenei's approval. Dozens have been arrested over the alleged siphoning of $2.6 billion of state funds. Five of those detained face execution. The president denies any government wrongdoing.
The feud among hardliners risks backfiring on both camps if voters, soured by the 2009 presidential election, ignore polls that offer them a limited choice in a strictly monitored system.
"In major cities, the vote is more politicised. However, I believe the turnout will not be very high as many people are still disappointed over the 2009 vote," said Farahvashian.