Afghan President Hamid Karzai called on the Taliban on Saturday to fight Afghanistan's enemies in what was widely seen as a swipe against Pakistan days after the neighbors' security forces clashed on their border.
Karzai's remarks are likely to unsettle already shaky ties with Pakistan and come as the United States wants Pakistan to help Afghanistan persuade the Taliban to engage in peace talks ahead of the withdrawal of most foreign troops by the end of next year.
"Instead of destroying their own country, they should turn their weapons against places where plots are made against Afghan prosperity," Karzai told reporters in the capital, Kabul, saying this was "a reminder for the Taliban."
"They should stand with this young man who was martyred and defend their soil," he said, referring to a border policeman who was killed in the Wednesday night clash on eastern Afghanistan's border with Pakistan. Two Pakistani soldiers were wounded.
A day earlier, thousands of men in Kabul rallied in support of the Afghan security forces.
Pakistan helped the Taliban take power in Afghanistan in the 1990s. Many Afghan leaders say Pakistan is still helping the militants, seeing them as a tool to counter the influence of its old rival, India, in Afghanistan.
Pakistan denies helping the militants and says it wants peace and stability in its western neighbour.
Karzai also revealed that he had spoken earlier on Saturday to the CIA's Kabul station chief, asking that the intelligence agency continue to provide payments to his country.
"Just this morning I met with the station chief of the CIA in Kabul and I thanked him for the support given to us in the past 10 years and I asked him to continue the support," he said, adding that the money was "flowing to" Afghanistan's intelligence agency, the National Directorate of Security.
"In the situation of Afghanistan where there is so much need ... it proves extremely helpful."