The Iranian foreign minister promised "all-out war" in the event of any military strike on Iran after the U.S. accused the country of being behind attacks on Saudi Arabian oil fields.

Foreign Minister Javad Zarif told CNN on Thursday that Iran was aiming to avoid any conflict, but was clear what the response would be to any U.S. or Saudi attack.

Secretary of State Mike Pompeo was in Jeddah, Saudi Arabia, on Wednesday to help coordinate a response and said that the oil field attacks had "the fingerprints of the ayatollah." President Donald Trump promised substantially increased economic sanctions on Iran.

Iran has consistently denied it was behind that attack, which it said was the work of Yemeni rebels.

Referring to the allegation Iran was behind the attack, Zarif told CNN: "Why do they want to make that up that it was from Iranian territory? The Yemenis have announced responsibility."

Pressed on this, Zarif said he only had the Houthis' statement claiming responsibility as proof.

"I am sure Iran didn't do it," he added.

.@npwcnn: What would be the consequence of an American or Saudi military strike on Iran now?



Iran Foreign Minister Javad Zarif: An all-out war.



More: https://t.co/PllvEJnYBj pic.twitter.com/L8rwbEwI3d — CNN International (@cnni) September 19, 2019

Asked by CNN's Nick Paton Walsh what the consequence of a U.S. or Saudi strike on Iranian soil would be, Iran's Zarif replied: "All-out war."

Told that is a serious statement, he replied: "Well, l I make a very serious statement about defending our country. I'm making a very serious statement that we don't want war, we don't want to engage in a military confrontation.

"We believe that a military confrontation based on deception is awful. There will be a lot of casualties. But we won't blink to defend our territory."

Zarif is planning to travel to the United Nations General Assembly in New York on Friday, a spokesperson for the foreign ministry told NBC News.

Pompeo on Thursday traveled to Abu Dhabi in the United Arab Emirates, which announced it will join the U.S.-led coalition of nations guaranteeing safe passage through the Strait of Hormuz, where several ships have been seized by Iranian authorities in recent weeks.

U.S. intelligence sources told NBC News on Tuesday that the attack originated geographically in Iranian territory. Two U.S. officials familiar with the then-latest intelligence said a series of cruise missiles were fired from at least one location in western Iran.

Earlier in the week, three U.S. sources said that indicated the attack originated from Iran.

However, Saudi Defense Ministry spokesman Col. Turki al-Malki on Wednesday said that the exact launch point for the attack had not yet been identified, but described it as “sponsored by Iran.”