The British tried invading Afghanistan three times, in 1839, 1878 and 1919; the Russians twice, in 1929 and 1979, and the US once in 2001. Generally, the results have been the same. Foreign forces could hold the cities and forts, but never the countryside; and at night, the occupiers' writ ran barely at all.
Testimonies to the futility of external attempts to control the Afghan state have been numerous. As early as 1921, the Russian General Snesarev was moved to write that "the country is extremely well-adapted to a passive resistance. Its mountainous nature and the proud and freedom-loving character of its people, combined with the lack of adequate roads, makes it very difficult to conquer and even harder to hold."
Alas, it seems that the obvious lesson has never been learnt, as the current quagmire and the experience of the Soviet Union in the 1980s shows. Indeed, common wisdom has it that the USSR suffered the most grievous consequences of its ill-starred intervention - nothing less than the collapse and dismemberment of its Communist empire.
Not so, says Sir Rodric Braithwaite, who as British ambassador to Moscow 1988-92 had a ringside seat during those feverish times. In fact, his fluent, compelling new account of the Russian misadventure in Afghanistan suggests that almost everything about the accepted Western narrative of that war is completely wrong. It was not an imperial gambit by clueless gerontocrats in the Kremlin to push towards a warm water port in the Indian Ocean. Although the economic and military costs were considerable, they were small compared with the USSR's overall commitments; the Soviet system was falling apart anyway. And the war was not won by US Congressman Charlie Wilson arming the heroic mujahideen with Stinger anti-aircraft missiles, however much that makes a comforting tale for the Western powers, whose own involvement in Afghanistan, one has to conclude after reading Braithwaite's book, has been even more catastrophic than the Russian intervention.
In 1978 the Communists had taken over in Kabul. But they did not consult with Moscow before ousting the republican regime of President Daud, who had himself overthrown the monarchy headed by his cousin, Zahir Shah, in 1973 - because they would have been told not to.
The Soviet leader, Leonid Brezhnev, had satisfactory relations with Daud and, internationally, was still trying to salvage something from the detente policy. The Afghan Communists, on the other hand, were fanatical reformers who believed that the conservative Muslim society "could be forced into modernity at the point of a gun". Revolts broke out straight away and Kabul repeatedly asked for troops to quell the insurgency. But far from eagerly rushing in, the Soviet leadership was united in rejecting their demands. The religious, peasant economy was not ready for socialist revolution, and one that had to be sustained by shooting people was not one the Kremlin wanted to support. Afghan president Nur Muhammad Taraki was warned that he needed to widen his political base, stop the repression and allow religious freedom.
The Soviet attitude was consistently cautious. Only when Taraki, whose safety had been personally guaranteed by Brezhnev, was killed by his increasingly unstable and erratic prime minister, Hafizullah Amin, did their view change. "What a bastard, Amin, to murder the man with whom he made the revolution," said the Soviet leader. "Who will now believe my promises, if my promises of protection are shown to be no more than empty words?" The decision was taken to mount a short police action: remove Amin, who was suspected of making overtures to the Americans; help the Afghan government regain control of the country (they only held 20 per cent of it by this point); and secure their southern flank, and the Muslim- majority Soviet Central Asian republics, against the "New Great Ottoman Empire" the KGB believed the CIA wanted to set up to oppose the Soviets. The aim was to be out within six months to a year.
"Their decision to intervene," writes Braithwaite, "was certainly a grave error of policy. But it was not irrational." Neither was it unjustifiable. In less than two years as prime minister and president, Amin had been responsible for executing up to 50,000 people, which he excused, to the irritation of his Soviet advisers, by saying: "Comrade Stalin showed us how to build socialism in a backward country. It's painful to begin with, but afterwards everything turns out just fine."
No such happy ending was to transpire. Although in a limited military sense the invaders were successful - they never lost a major battle nor any armed posts - 15,000 Soviet soldiers and as many as 1.5m Afghans died during the following decade, and much of the country once known as "the Switzerland of the East" was destroyed.
As soon as the last of the old leaders - Brezhnev, Andropov and Chernenko - had died in office, the Soviets were determined to find an exit. Gorbachev took the decision to pull out in 1985, more than a year before the first of Charlie Wilson's Stingers was fired.The Soviets recognised that they had become disastrously embroiled in an interminable civil war whose roots went back at least as far as 1975, when Gulbuddin Hekmatyar had led a brief Islamist uprising against Daud's government. Far from their withdrawal leading to a free and peaceable Afghanistan, Gorbachev presciently predicted in 1987 that it would be followed by a bloodbath "for which we would not be forgiven, either by the Third World, or by the shabby Western liberals who have spent the last ten years lambasting us for occupying the place".
The West did not see it this way, however. To the Americans, "even the least reputable of the mujahideen leaders" became seen as "heroes". Some of them were very disreputable indeed, and more than kept score with the Soviets for atrocities. On one occasion Soviet soldiers were chopped up and sent back as an assortment of body parts. Another captured private was castrated, had a ring put through his nose and was dragged naked through the villages for a month before being finished off. Hekmatyar, the main beneficiary of support from both the Americans and the Pakistanis, was arguably the worst of a bloodthirsty, venal and quarrelsome lot. But not even Ahmad Shah Masud, the "Lion of the Panjshir" later idolised in the West as leader of the Northern Alliance against the Taliban, can escape such charges. In one incident, the local river is said to have run red with blood after his men took one thousand Afghan soldiers prisoner and then shot the lot.
Within a few years men such as Hekmatyar were to become allies of Al Qaeda. He was declared a "global terrorist" by the US State Department in 2003, while the southern warlord Jalaluddin Haqqani, declared "goodness personified" by Charlie Wilson, ended up as number three on the Americans' "wanted list" after September 11.
I would say they should have known better in continuing to back mujahideen of any stripe until the fall of the last Communist president, in 1992. But they did know better. The CIA reported that he would likely be replaced by an Islamic fundamentalist regime that "may be actively hostile, especially towards the United States." That is exactly what happened when the Taliban took power in 1996 after, as Braithwaite puts it, the Afghans decided that "anything ... would be preferable to a particularly murderous civil war."
Today, the West is still dealing, not with the post-September 11 decision to go after Osama bin Laden, but that to embark on yet another ill-conceived intervention in Afghanistan. If it was too much to expect the Americans to draw lessons from the British experience, the Russians' occupation was surely recent enough for someone to have reminded the White House that Afghans do not take kindly to anyone telling them what to do; and that to try to impose what many of them view as a godless, permissive creed - liberal democracy - was not only a fool's errand. It was a criminally ignorant one, too.
Sholto Byrnes is a contributing editor of the New Statesman.