The threat from Daish, the Arabic acronym for the so-called Islamic State in Iraq and Syria, has gone from a side issue to a central imperative, judging by discussions with Kurdish leaders on my four fact-finding trips to the Kurdistan region in the last year.
Last November, I was told how Daish operatives were assiduously measuring building sites in Mosul in an extortion racket. In February, I learned of their external funding and their continuing growth. In June, they captured Mosul with a small force that immediately acquired thousands of adherents, and established a 650-mile border with the Iraqi Kurds.
The major shock, though, was how quickly the Iraqi Army had 'disappeared in a puff', as the governor of Kirkuk put it to me in his office in the city. Kurdish leaders knew that Daish would turn its guns on them, but were taken by surprise in early August.
Daish forces outgunned the Kurdish Peshmerga, who had to retreat in some places. Daish came within artillery range of the capital, Erbil, and sparked panic through deliberate and inadvertent confusion on social media. It is not surprising that roughly one-third the population of Erbil fled. Some Syrian refugees in the region even returned to Syria.
The threat to Erbil was so serious that the Americans finally undertook airstrikes that stemmed Daish. The threat has now abated but no one is complacent. A senior Kurdish figure explained to me the seriousness of the military and political strategy of Daish. They used game theory to provoke war, and turned themselves from a local into a global force with volunteers from 81 countries. Their branding of beheadings and brutality made them instantly recognisable above their would-be jihadi competitors.
Their tactics are novel and devastating, using explosive-laden vehicles to soften defences and then a charge of fighters. Having cleared villages of people, they retreat, leaving nests of booby traps in and around the villages. Over four-fifths of Peshmerga deaths have been caused this way. De-mining and first-aid training are essential.
A major lesson of early August is that the Peshmerga lack a unified command, and were stymied by being divided on political lines. Their bifurcation goes back to the bitter civil war of the 1990s, which is still very raw for supporters of various Kurdish factions, who do not trust the others for protection. Longstanding calls for reforming the region's security forces are now accepted by all parties.
But the Peshmerga also need heavy weapons. I am no military man but some simple points are clear; A sniper rifle with a range of one mile cannot overcome one with two-miles range; AK-47s without armour-piercing shells will be trumped by guns that can slice through armour; The Kurds' Toyota pick-ups and improvised-armoured cars are no match for armoured Humvees and tanks. The Kurds need heavy machine guns, better sniper rifles, artillery, tanks, armoured personnel carriers, anti-tank weapons and helicopters.
The Kurdistan parliament speaker told me that Western weapon-supplies are minimal. Baghdad, the nominally sovereign power in the region, resists such supplies, because the leaders there fear such firepower could advance Kurdish independence. The Americans had allocated military supplies to the Kurds when they left Iraq in 2011, but Baghdad refused to pass them on.
If Baghdad and Erbil solve their longstanding and outstanding disputes on land, oil, exports and budgets, then talk of independence will fade. Arguments about a revived federalism will come to a head in early December when the Kurds assess Baghdad's willingness to reverse former Prime Minister Nouri al-Maliki's punitive approach to the most successful part of Iraq, and to the Sunnis - who could be persuaded to turn on Daish.
There are some signs of change. The controversial office of the commander-in-chief of the Army, which Maliki used to centralise power, is being overhauled. There is also a strong case for ending the de-Baathification programme, seen as almost exclusively anti-Sunni, while retaining the right to pursue those who have blood on their hands. Without a breakthrough, a looser confederation or - maybe later rather than sooner - Iraqi Kurdish rights to self-determination will go live.
The Kurds have always been defensive and will not attack Baghdad. The pressing priority is to help the Kurds defend their homeland. See how Turkey has swallowed reservations and allowed arms from Iraqi Kurdistan into Kobane. First things first. Stop Daish.
Gary Kent is the director of the UK's all-party parliamentary group on the Kurdistan Region. He has visited Iraq 19 times since 2006, and writes in a personal capacity.