The dramatic vow to defend the country's sovereignty underlined the lack of a common strategy between key allies in the seven-year war on terrorism. It also overshadowed efforts by civilian leaders in Pakistan to defuse the dispute with diplomacy.
Admiral Mike Mullen, the top US military officer, arrived in Pakistan for meetings with civilians and military leaders amid the increased tensions.
Pakistani leaders were embarrassed by a highly unusual September 3 ground attack by US commandos into South Waziristan, a base for Taliban militants killing ever more US troops in Afghanistan. Some observers warned that the threat to respond with lethal force in the event of another incursion should be taken seriously.
"No country in the world can allow ground troops -- enemy or otherwise -- to come into its territory and carry out any unilateral action," said Ikram Sehgal, a Pakistani defence analyst. "The Americans have to back down on this."
But others forecast that the consequences of alienating Pakistan's chief benefactor -- both to the military and its struggling economy -- would stay the army's hand.
"If an American soldier were to die because of Pakistani military firing that would damage the Pakistani-American relationship for years to come," another analyst said.
The orders were disclosed by army spokesman Maj. Gen. Athar Abbas in a press interview. Abbas said Pakistani field commanders have previously been flexible and tolerant of international forces crossing a short way into Pakistan because of the ill-defined and contested nature of the mountainous frontier.
"But after the (September 3) incident, the orders are clear," Abbas said. "In case it happens again in this form, that there is a very significant detection, which is very definite, no ambiguity, across the border, on ground or in the air: open fire."
Neither Washington nor Pakistan's government issued a clear response. Pentagon spokesman Bryan Whitman said Pakistan would "correct the record" on the statement from Abbas.