USS Harry S. Truman
USS Harry S. TrumanReuters

The Iranian navy test fired several rockets near three Western warships, including the USS Harry S. Truman aircraft carrier last week, an American military official said Tuesday, according to AFP.

Though the rockets were not fired toward any ship, their proximity to the warships -- and several commercial vessels -- sparked concern.

"We look at this firing so close to the ships as highly provocative," said the military official, who was not immediately authorized to be named.

The official confirmed details of an NBC News report that said one rocket came within about 1,500 yards (meters) of the USS Truman as it transited the Strait of Hormuz.

The incident took place on December 26, shortly after the Iranian navy had announced via radio it was about to conduct a live-fire exercise and warned ships to steer clear, according to AFP.

The official said the unguided rockets were fired from an Iranian navy "fast inshore attack craft" that was in Omani waters.

The Western vessels did not need to take evasive action, the official said.

Iran, which frequently conducts missile tests and maneuvers to underline its military muscle, has repeatedly threatened to close the Strait of Hormuz to oil tanker traffic should it be attacked.

The strait is a narrow channel at the entrance of the Gulf through which a third of the world's traded oil passes.

The United States has warned Iran that any attempt to close the strait would be viewed as a "red line" -- grounds for U.S. military action.

The incident also comes days after it was revealed that Iran tested a ballistic missile, for the second time in a month.

The tests have been determined to be a violation of a UN Security Council resolution.