TEHRAN — Iran’s defense minister on Friday confirmed that Iranian warplanes had fired shots at an American drone last week, but said that they had taken the action after the unmanned aircraft had entered Iranian airspace.

The assertions by the defense minister, Brig. Gen. Ahmad Vahidi, were the first acknowledgment from Iran that the episode had occurred. He spoke less than 24 hours after the Pentagon first disclosed the shooting, involving two Iranian jet fighters and the American aircraft, a Predator surveillance drone, during what American officials described as a routine surveillance mission on Nov. 1 in international airspace over the Persian Gulf.

It was the first time that Iranian aircraft had been known to fire at an American drone, one of the many ways that the United States has sought to monitor developments in Iran over more than three decades of estrangement between the two countries. The United States said it had protested the shooting via the American interests section at the Swiss Embassy in Tehran, and had warned the Iranians that the drone flights would continue.

Political risk analysts noted that the firing had taken place days before it was clear whether the American elections would be won by President Obama or his Republican challenger, Mitt Romney, who was far more hawkish than Mr. Obama in his public criticism of Iran during the campaign. Some said the episode may have been meant by the Iranians as warning message regardless of the outcome of the election. “The early November incident was probably an attempt by Iran to intimidate the next U.S. administration and gain leverage in future diplomacy,” said Cliff Kupchan, an Iran specialist at the Eurasia Group, a consulting firm in Washington.