With tens of thousands of troops, tanks and fighter planes massed on the border, Iran warned Afghanistan's Taliban religious army Saturday that it would take "necessary measures" to win the release of 11 diplomats and 31 other Iranian hos-tages.

Meanwhile, American intelligence analysts alerted senior administration officials of the "potential for incursion" by Iran, a U.S. intelligence source said.State-run Tehran radio said Saturday that Iran would take "the necessary measures within the framework of legitimate defense," but it did not specify what that action could be.

The military buildup and threat comes with Iranian newspapers and analysts speaking increasingly of a possible military strike against the Taliban Islamic militia, which controls nearly all of Afghanistan.

Iran carried out military maneuvers on its Afghan border this week in which 70,000 troops, more than 150 tanks and squadrons of fighter planes were involved. Tehran has said the forces will remain in the area.

"They've got some forces assembled and they're making noises," said the U.S. intelligence source, who spoke on condition of anonymity.

For the past week U.S. spy satellites have been monitoring Iranian troop movements, but the exercise quickly developed into an operation aimed at getting troops in position to spring across the Afghan border, the source said.

"They certainly are positioned for something," the intelligence official said.

Iran accuses the Taliban of seizing 47 Iranians when its forces captured the northern city of Mazar-e-Sharif on Aug. 8.

The Taliban says it knows nothing about the 11 diplomats, but it freed five Iranian truck drivers on Thursday.

"I think that whether we like it or not, we are heading toward some kind of military confrontation with the Taliban," Sadegh Zibakalam, professor of politics at Tehran University, said in an interview with the newspaper Toos.

But, with memories of a costly 1980-88 war against Iraq still fresh in Iranian minds, newspapers in Iran have warned the government against stepping into a quagmire.

The hard-line Qods daily said Saturday that the Taliban must be taught a lesson.

"But this lesson must follow a thorough understanding of all the aspects and consequences," the paper warned.

Iranian officials say there is a growing sense that the diplomats have probably been killed.

A member of an Iranian delegation that traveled to Afghanistan last week said their mission was only to find and retrieve the remains of the diplomats.

Iran's newspaper Abrar has quoted Taliban spokesman Wakil Ahmed Mutawakil as saying the diplomats were probably killed by opposition forces during the battle for Mazar-e-Sharif.