Since 9/11, it has sometimes seemed as if the world has become consumed by battles with Islamist terrorists. From Iraq to Afghanistan, via Mali and Algeria, commentators have long argued that we are witness to a clash of civilisations.
But in the Philippines, the story is very different. After 40 years of revolutionary struggle over land, resources and religion that has claimed 120,000 lives and displaced more than 2 million people, a hardline Islamist rebel movement is slowly but surely coming in from the cold in the lawless south.
Inspired in part by the Good Friday agreement in Northern Ireland, and encouraged by a reformist presidency in Manila, the Moro Islamic Liberation Front (MILF) has broken with al-Qaida-linked regional terrorist groups blamed for the Bali nightclub bombings and cast its lot for peace.
In a historic break with the past, Benigno Aquino, the Philippines president, visited the MILF stronghold in Mindanao earlier this week to meet rebel leaders and launch a new joint development programme to underwrite the peace process.
Aquino said the government and MILF leaders were within weeks of finalising agreement on a joint transition commission, chaired by the rebels, that will oversee the creation of a new, self-governing Muslim political and geographical entity, the Bangsamoro – literally, the land of the Moro (derived from Moors, the name given to Mindanao's indigenous peoples by Spanish colonialists). "I think we're very, very close to agreements on all points," he said.
If all goes to plan in the Malaysian-mediated talks and if a new basic law produced by the commission is ratified by the Philippines congress, the Bangsamoro state within a state will come into formal existence by 2016, when Aquino, a passionate advocate of the peace process, is due to step down.
"When you look at the confrontations with Islamists in Mali, in Afghanistan, in Syria, and you see what's happening in Mindanao, it's a marvellous example of what can be done when you really want," a western analyst said.
"We are almost there on the outstanding issues, we can say we feel guarded optimism," said Jun Mantawil, head of the MILF secretariat and a member of the front's negotiating team, in an interview in Cotabato City, in western Mindanao. "There is a big signing ceremony in prospect when the agreement is finalised. We're confident the president can get it through congress."
Teresita "Ging" Quintos Deles, presidential adviser on the peace process, and Miriam Coronel Ferrer, chair of the government's negotiating panel, interviewed in Manila, agreed there was a sound basis for optimism.
"The road map on the table is real. I don't get a sense that it will break down now. The annexes [to last October's framework agreement] will be completed by March at the latest," Deles said. The transition commission would probably be unveiled this month.
But Deles warned against over-inflated expectations. "We are engaged in a race against time. There is a limited window, and this has been transmitted to [the MILF]. The president has always said his capacity to deliver has a limited shelf life … the MILF can choose to go for a perfect agreement, or to go for a more limited package that you can be sure will be delivered," she said.
Issues under discussion include territory, power-sharing, wealth-sharing, and normalisation, including demobilisation, disarmament and reintegration.
Mantawil, the MILF negotiator, said there were "sticking points" over the extent of the maritime area the new Bangsamoro authority would control, and over future revenues from supposedly vast but so far unquantified oil and gas fields that lie beneath the inland Liguasan marsh and off the Sulu archipelago, to the west of Mindanao island.
A 2006 cable from the US embassy in Manila, published by WikiLeaks, suggested the energy and mineral resources in MILF-controlled areas of Mindanao could be worth up to $1tn.
Unconfirmed reports circulating in 2011, when Aquino kickstarted the peace process with a breakthrough meeting with the MILF chair, Murad Ibrahim, in Tokyo, claimed Washington was pushing Manila for a peace deal in order to open up the area for energy exploitation.
What to do with the MILF's estimated 12,000 armed fighters is another vexed issue. The framework accord calls for the creation of an impartial civilian "police force for the Bangsamoro", the decommissioning of MILF cadres, and a handover of responsibility for security from the Philippines army to the new police force.
International support will be sought to assist "combatant and noncombatant" rebel elements to return to normal life, it says.
The negotiators' approach to policing and decommissioning was influenced by the British experience in Northern Ireland, Deles said. In an echo of the Good Friday agreement, the MILF has undertaken to put its weapons "beyond use".
Britain is a member of an international contact group promoting a peace deal, along with Japan, Turkey and Saudi Arabia. In his interview with the Guardian, Mantawil said he had visited London, Belfast and Dublin to study the peace process there.
"It is a very similar situation to us [in Northern Ireland]," he said. "It was very encouraging for us. The Good Friday agreement is a bit of a model … decommissioning [of weapons] is very difficult to manage. In Northern Ireland they had a commission. Maybe we should, too."
A recent report by the independent International Crisis Group struck a cautionary note. "The pact suggests fighters will help maintain peace and order while decommissioning is under way. But sceptics note there are plenty of thugs under the organisation's umbrella who should not be allowed to play any kind of policing role, formally or informally. The MILF understands these concerns …"
Mantawil said the MILF had severed its ties with Abu Sayyaf, an al-Qaida affiliate active in the lawless Sulu archipelago that has a history of seizing western hostages for ransom, or else beheading them. Clashes last week between a MILF splinter group and Abu Sayyaf fighters in Jolo reportedly left 30 people dead.
The MILF leader also distanced his organisation from Jemaah Islamiyah, the south-east Asian jihadist terror group that bombed Bali in 2002 and has launched attacks in Jakarta. "These people do not believe in peace. They are dissidents. We broke with them when they turned to terrorism. They are not one of us," Mantawil said.
The prospective end to violence in Mindanao has inspired civil society organisations to launch an urgent drive to shape the peace, with the emphasis on raising living standards in the Philippines' most impoverished and economically deprived region and on ensuring equal rights for women.
The international aid agency Oxfam has developed partnerships with local organisations to improve access to basic education and boost awareness of the peace process and indigenous people's rights. Known as the Oxfam Mindanao programme (OMP), the scheme is "designed to achieve sustainable livelihoods and greater protection for the Lumad [non-Muslim indigenous tribes], Moro, [and] small asset-holders".
The OMP, due to run until 2014, has disbursed £3m to date. Oxfam is also supporting a coalition of groups intent on securing open and transparent governance.
Aid workers said the prospect of a self-governing, semi-autonomous Bangsamoro, replacing the failed autonomous region in Muslim Mindanao set up by government fiat in the 1980s, has received a broad welcome. But they warn it could work to the disadvantage of some groups, especially women. The MILF says, for example, that it plans to extend the use of sharia law. What that will mean in practice is as yet unclear.
In the Moro village of Macasampen, outside Cotabato City, Oxfam is backing a local group, known as UnYPhil (United Youth of the Philippines – Women) whose main aim is to provide assistance to women subjected to violence, sexual and physical abuse, or discrimination.
Anna Bai, a UnYPhil activist, said the villagers had suffered greatly during the war between government troops and the MILF. "Sometimes gunfights would force us to leave the village several times a day. We were frightened and didn't know where to go. We didn't know whether we'd be alive the next day. The children were badly affected. They didn't want to go to school. Now they are frightened of loud noises. They have a phobia."
Bai said most people in the village supported the Bangsamoro plan but admitted they did not know much about it. "We don't have a copy of the agreement. We listen to what the government and the MILF say." On the question of equal rights, "each woman should have her own livelihood that is protected", Bai said. But a continuing sense of insecurity meant many women were still "a bit afraid" to go to the fields and forests to work.
Another villager, Aida Manpli, said her biggest worry was lack of money, a challenge common to most rural families. "I am a housewife," she said. "I take care of my four children. I want them to go to college. My eldest is 17. She wants to be a midwife. But I am telling her we probably can't afford it because my husband is a farmer."
Deles said increased government spending on infrastructure and social and economic development, prioritising education, health and livelihoods, was central to the Bangsamoro road map. Some analysts predict that, if carefully managed, resource-rich Mindanao could one day become the industrial and agrarian powerhouse of the Philippines.
"There is big development potential but it must be done in such a way that we do not create new problems and the benefits are shared. We must go carefully," Deles said.
Despite widely shared optimism about the future, many other obstacles to a lasting peace remain. They include possible opposition from Christian settler groups, a stalemate in congress after crucial national elections due in May, a falling off in Aquino's current, remarkable popularity, and further splintering of the MILF if quick results are not forthcoming. The island rulers of the Sulu archipelago, for example, are notoriously unbiddable.
Difficulties may also arise if the MILF does not take full account of the views of Mindanao's non-Muslim indigenous peoples, or Lumad, also known as the Bangsa-Mamalu, some of whose tribal leaders are now straining administrative coherence by seeking autonomous status within the new semi-autonomous Bangsamoro.
Although the MILF has promised an inclusive approach, Mantawil insisted the front would have sole charge of the proposed Bangasamoro transition authority prior to planned elections in 2015.
"Of course we must lead it. We fought for it for 40 years. We must have a clear majority," he said. Groups that opposed this were "counter-revolutionary".
Asked about such demands, Deles exhibits a patient smile. "If this process is to work, no elements of the Bangsamoro should feel they are being excluded," she said. After decades of military campaigning, "the MILF needs to show they can now behave like a political organisation.
"Every bit of the government is doing its bit to find a solution." "We cannot afford more damage to hope and confidence. We cannot afford not to have a happy ending."