The attack on the Pakistani embassy in Kabul on Tuesday is a fallout of the tension that has been building up on the largely ill-defined border between Afghanistan and Pakistan.
That follows Islamabad's decision in late June to send its troops to the north-western tribal region of Mohmand Agency.
This was a significant military operation aimed at extending the writ of the Pakistan Government to the semi-autonomous, lawless tribal areas bordering Afghanistan.
The attack was triggered by border tensions
Its success prompted President General Pervez Musharraf to exultantly remark during his recent tour of the US, Britain, Germany and France that this was the first time in over a century that Pakistani forces had entered this area, where they were searching for al-Qaeda members.
He described the tribal borderland as a treacherous area where Osama Bin Laden may be hiding along Pakistan's border with Afghanistan.
The military incursion triggered cross-border exchanges of fire between Afghan and Pakistani forces and caused some casualties on both sides.
Afghan provincial authorities in eastern Nangarhar and Kunar provinces alleged that Pakistani troops had intruded to establish about a dozen border posts inside Afghanistan.
Pakistan denied the allegation, arguing that it had set up the outposts on the Pakistani side of the Durand Line border.
The incident revived the old border disputes that had strained relations between the two neighbouring Islamic countries since Pakistan's creation in 1947.
Past efforts to resolve the border disputes by setting up joint commissions, including one formed during the rule of the Taleban, had failed to make any headway.
The US role in the matter has assumed added significance because its forces have been hunting down al-Qaeda and Taliban fighters in both Afghanistan and Pakistan since October 2001.
Even during the recent Pakistani military operations in the Mohmand tribal region, US troops were deployed across the border in Afghanistan to block al-Qaeda and Taleban fighters from crossing into Pakistan.
The US and Pakistani forces have been coordinating with each other in the war on terrorism and it was largely on Washington's insistence that Islamabad deployed more than 60,000 soldiers and militia on its border with Afghanistan and extended its writ to its hitherto unadministered and inaccessible tribal areas to prevent al-Qaeda and Taliban fighters from hiding there and launching cross-border attacks.
The US military authorities in the region could be expected to want to defuse the tension between Islamabad and Kabul.
The tension could affect their efforts to flush out remnants of al-Qaeda and Taleban and put a halt to the growing number of attack on their troops in Afghanistan.
Matters were not helped when Afghan President Hamid Karzai objected to certain reported remarks of Pakistani President Pervez Musharraf questioning Mr Karzai's influence and writ of his government across Afghanistan.
Tribal bonds dilute the Pakistan-Afghanistan border
An on a mosque in the south-western Afghan city of Kandahar, and the slaying of 53 men praying in a Shiite mosque in Quetta, capital of neighbouring Balochistan province in Pakistan, also fuelled tension amid accusations of "foreign involvement" in these acts.
Officials in the Afghan Government have often alleged that al-Qaeda and Taleban fugitives took refuge in Pakistan after escaping the US-led campaign against them in Afghanistan.
Pakistan, for its part, is suspicious of the role of the Northern Alliance, the militarily powerful group that dominates the Karzai government.
The flare-up on the border was the spark that brought to the fore the simmering disputes that have bedevilled relations between Afghanistan and Pakistan in the past.