David Cameron's post-WikiLeaks remarks on Pakistan helping the enemy in the Hindu Kush shouldn't be taken too seriously. The carefully orchestrated "outburst" in India was designed to please his hosts and seal a few business deals (Cameron and Cable are fagging for the British arms industry). It's all part of the schmoozing.

Pakistan's official response was equally disingenuous. Since it's impossible for Islamabad to attack the organ grinder, it went for the monkey.

Meanwhile all sides know full well what the Pakistan army has been doing with various Taliban factions since Afghanistan was occupied nearly nine years ago. Three years ago a US intelligence agent was shot dead by a Pakistani soldier at such talks – as reported in the Pakistani press. A source close to the Pakistani military told me last year in Islamabad that US intelligence agents were present at recent talks between the ISI and the insurgents. No reason for anybody to be surprised. The cause, too, is clear. The war cannot be won.

It's hardly a secret that Pakistan never totally abandoned the Taliban after 9/11. How could they? It was Islamabad that had organised the Taliban's retreat from Kabul so that the US and its allies could take the country without a fight. The Pakistani generals advised their Afghan friends to bide their time.

As the war in Afghanistan deteriorated, the insurgency grew. It was the social chaos and the political corruption of Hamid Karzai's outfit that made a foreign occupation even worse in the eyes of many Afghans, bringing a new generation of Pashtuns into battle – young men who had not been part of the displaced regime. It is this neo-Taliban that has effectively organised the spread of resistance, which as the IED diagram revealed by WikiLeaks showed, extends to virtually every part of the country.

Matthew Hoh, a former marine captain serving as a political officer in Afghanistan, resigned from the service in September 2009. His explanation was clear: "The Pashtun insurgency, which is composed of multiple, seemingly infinite, local groups, is fed by what is perceived by the Pashtun people as a continued and sustained assault, going back centuries, on Pashtun land, culture, traditions and religion by internal and external enemies … I have observed that the bulk of the insurgency fights not for the white banner of the Taliban, but rather against the presence of foreign soldiers and taxes imposed by an unrepresentative government in Kabul."

In 2007, the US attempted to wean a section of the insurgents away from Mullah Omar, the Taliban leader, by offering them government positions. The neo-Taliban leaders refused to join a government while there were foreign troops in the country. But in order to make the contacts in the first place, the Pakistan army was critically important. This army, used as cover by the US on several occasions, was now forced to shed its Islamist skin (necessary for the jihad against the Soviet Union). This angered many within its ranks, and there were three attempts on General Musharraf's life.

The ISI, whose autonomy was always overrated, was brought under almost total control, and General Ashfaq Kayani (who replaced Musharraf as chief of army staff) re-organised it from top to bottom. A few rogue elements revealed themselves when they approved the attack on the Indian embassy in Kabul in 2008; they were immediately disciplined and removed. Today, attacking the ISI has become convenient for the west, who need General Kayani and so cannot attack him directly. There is no way the ISI or any other wing of the military could help the insurgents without Kayani's knowledge – and Kayani knows full well that in order to preserve contacts the insurgents fighting Nato have to be offered a few carrots.

Karzai was so desperate a few months ago to woo the Taliban that he requested General Eikenberry, the doveish US ambassador in Kabul, to remove the entire Taliban leadership, including Omar, from the most wanted list. Eikenberry did not refuse but suggested each case be considered on its merits. What better indication that the war is lost.

WikiLeaks appear to have revived Karzai temporarily. "It is a different question whether Afghanistan has the ability to tackle this," he said in response to a question about Pakistan support for the Taliban, "... but our allies have this capability. The question now is, why they are not taking action?"

But they are. And have been since Barack Obama became president. The drone attacks were intended to burn out support for the insurgents across the border. Instead, they have resulted in destabilising Pakistan. Last year, the army forcibly removed 250,000 people from the Orakzai district on the Afghan border and put them in refugee camps. Many swore revenge, and militant groups have targeted the ISI and other military centres. On 8 June this year militants bearing grenades and mortars attacked a Nato convoy in Rawalpindi. Fifty Nato vehicles were burnt and more than a dozen soldiers were reported dead.

This can only get worse. Time for Obama to abandon all pretences used to justify a war that can only lead to more deaths but no solution. An exit strategy is now desperately needed.