Updated

President Trump and Iranian Foreign Minister Javad Zarif sparred on Twitter early Friday as the president warned that the country is “playing with fire” in the wake of recent missile tests – and his administration prepares to announce new sanctions.

A White House source told Fox News the sanctions will be announced Friday morning.

After his administration put Iran “on notice” earlier this week, Trump fired his latest warning shot on Twitter, writing: “Iran is playing with fire - they don't appreciate how "kind" President Obama was to them. Not me!”

Zarif swiftly posted a response, saying: “Iran unmoved by threats as we derive security from our people. We'll never initiate war, but we can only rely on our own means of defense.”

He also said Iran “will never use our weapons against anyone, except in self-defense. Let us see if any of those who complain can make the same statement.”

Under new sanctions, up to two dozen Iranian individuals, companies and possibly government agencies reportedly could be penalized.

The sanctions, coming in the first weeks of Trump's term, reflect his administration's desire to take a strong stance toward Iran from the start. Throughout his campaign, Trump accused the Obama administration of being insufficiently tough on Iran and vowed to crack down if elected.

It was unclear exactly which entities would be sanctioned. Many sanctions on Iran that had been imposed in response to its nuclear program were lifted in the final years of the Obama administration as part of the nuclear deal the U.S. and world powers brokered. Some of those penalties could be re-imposed under separate sanction authorities unrelated to nuclear issues.

That prospect raises the possibility of a fresh confrontation between the U.S. and Iran, which has forcefully argued that it considers any new sanctions a violation of the nuclear deal. The U.S. has maintained that it retains the right to sanction Iran for other behavior such as supporting terrorism.

Trump’s team stepped up its rhetoric against Iran over ballistic missile tests and a recent attack on a Saudi naval vessel by Tehran-backed militants.

Military officials told Fox News that Iran actually has conducted two recent missile tests, one on Dec. 6 and another this past Sunday.

U.N. resolution 2231 calls on the Islamic Republic not to conduct such tests. The resolution bars Iran from conducting ballistic missile tests for eight years and went into effect on July 20, 2015, days after the landmark nuclear deal was agreed to in Vienna.

Fox News’ Lucas Tomlinson and The Associated Press contributed to this report.