By Jon Leyne
BBC News, Tehran
The Iranian president's speech was broadcast live on Iranian TV
Nobody was expecting a long and warm honeymoon but the vitriol in President Mahmoud Ahmadinejad's remarks to the new US administration was remarkable.
President Barack Obama, in his first foreign interview earlier this week, offered what he called the hand of friendship if Iran "unclenched its fist"
In response, Mr Ahmadinejad jumped back in the boxing ring and resumed a verbal volley of punches.
First he wished former US President George W Bush on his way: "God willing, he has gone to hell."
Then Mr Ahmadinejad laid before his audience the ever-growing list of grievances Iran holds against the US:
- American support for the coup that unseated a democratically elected Iranian government in 1953
- American backing for Saddam Hussein in the Iran-Iraq war
- Support for the "Zionist regime" [Israel]
- Launching the invasions of Afghanistan and Iraq under the pretext of 9/11 - an incident as questionable as the Holocaust, he suggested.
Americans had kept Iran away from scientific progress and injected the country with poverty, ignorance and illiteracy, he said. They had turned their embassy in Tehran into a "nest of spies", Mr Ahmadinejad continued.
The US needed to stop talking down to the rest of the world, to change its language and act respectfully, he went on. All American troops should return home. And Washington should apologise for its crimes against Iran.
It was an exceptionally long and angry tirade, even by the standards of Mr Ahmadinejad.
It was tempered only by a few slightly more encouraging words. If there really was a fundamental change in American policy, said Mr Ahmadinejad, then Iran would welcome it.
Tough talk indeed from the man who sent an unprecedented message of congratulations to the new American president after Mr Obama's election victory in November.
So have the hardliners won the policy battle in Tehran? Or is this Mr Ahmadinejad's eccentric way of opening a diplomatic dialogue?
Most observers in Iran believed Mr Ahmadinejad wanted some moves towards reconciliation with Washington, in order to help his bid for re-election in June.
But with a long silence from Tehran on policy towards Mr Obama, it was already clear that a fierce battle was going on behind the scenes.
In theory, it is the supreme leader, Ayatollah Khamenei, who is in charge of foreign policy, though in practice decisions seem to emerge from among a small group of senior officials, military officers and clergy.
When there are differences over policy, the default is always to return to the old certainties: "Death to Israel! Death to America!"
For Washington, this sort of hostility at least helps resolve one dilemma: the administration must be in two minds whether to launch a diplomatic initiative towards Iran before the Iranian presidential election in five months' time.
Why do anything now, when someone else might soon be in power ? After all, dealing with Mr Ahmadinejad was always going to be a high-risk policy.
One of Mr Obama's consistent calls, in his election campaign, was for negotiations with Iran without precondition. For any new dialogue, this was not a promising start.