Iran's President Mahmoud Ahmadinejad has said his country does not fear the US military and that any attack would be "severely punished".
Mr Ahmadinejad made the comments in a rare US television interview on Monday.
He was speaking after US officials said they had evidence Iran was providing weapons to Shia militias in Iraq who were attacking the US military.
Mr Ahmadinejad said Iran "shied away from all conflict" and that no peace would come with foreign troops in Iraq.
In the interview with ABC Television in Tehran, Mr Ahmadinejad was asked if he feared a US military attack.
"Fear? Why should we be afraid?" he asked.
Mr Ahmadinejad said he thought the possibility of such an attack was "very low".
"We think there are wise people in the US who would stop such illegal actions," he said.
And he stressed that Iran's position was clear, saying, "Anyone who wants to attack our country will be severely punished."
The Bush administration denies it is planning to invade Iran but has indicated it is willing to use military force to deal with any Iranian interference inside Iraq.
Mr Ahmadinejad was asked repeatedly about Iran supplying weapons to Shia militias.
He said the accusations were "excuses to prolong the stay" of US forces and that they would need a "court to prove the case".
"The US is following another policy, trying to hide its defeats and failures and that's why it is pointing its fingers to others," Mr Ahmadinejad said.
"There should be no foreigners in Iraq. And then you see that you have peace in Iraq," he said.
Earlier Iranian Foreign Ministry spokesman Mohammad Ali Hosseini had called the US allegations baseless propaganda.
He said Washington had a long history of fabricating evidence.
In the US, some Democrats also expressed concerns about levelling such accusations against Tehran.
Democratic Senator Chris Dodd said the Bush administration had tried to falsify evidence before, and it would be a mistake to create a premise for future military action.
On Monday, White House spokesman Tony Snow reiterated that the administration believed the weaponry was coming directly with Iranian government approval.
And a spokesman for UK Prime Minister Tony Blair said: "We keep finding the weaponry which we don't believe to be sourced from anywhere else."