Somali gunmen have released the head of the UN refugee agency's office in Somali capital Mogadishu after two months in captivity, the agency said Wednesday evening, according to dpa. Hassan Mohamed Ali, popularly known as Keynaan, was seized by gunmen on June 21, prompting protests by hundreds of people at internally displaced camps outside Mogadishu. "UNHCR would like to thank all Somali organizations and members of civil society who organized demonstrations to call for his release," the agency said in a statement. UNCHR said that Ali was in good health and was about to be reunited with his family. Aid workers have been increasingly targeted for attacks and abduction since the man believed to be al-Qaeda's top operative in Somalia, Aden Hashi Ayro, was killed on May 1 in a US airstrike. Ayro was the leader of Islamic militant group al-Shabaab, the armed wing of the Union of Islamic Courts (UIC). Militants have been waging a guerrilla war against government troops since the UIC was ousted from power at the beginning of 2007 with Ethiopian assistance. Aid agencies say that over 6,000 civilians have been killed in the crossfire and hundreds of thousands have fled Mogadishu to live in camps. According to the UN's latest food security report, 3.2 million Somalis - 43 per cent of the entire population - are dependent on food aid. The interim government has been unable to achieve stability in the Horn of Africa country, which has been plagued by chaos and civil war since dictator Mohamed Siad Barre was toppled in 1991.