KABUL - Afghan President Ashraf Ghani on Sunday rejected the resignations of the intelligence chief and the interior and defence ministers, as the government faces fierce criticism over an increasingly deadly insurgency. Ghani called on Defence Minister Tariq Shah Bahrami, Interior Minister Wais Ahmad Barmak and intelligence chief Masoom Stanekzai to continue their duties, after rejecting their resignation letters submitted Saturday and demanding they help bolster the country’s defences.

“President Ghani did not approve their resignations... and gave them the necessary instructions to improve the security situation,” said a palace statement. Earlier Saturday Ghani’s powerful national security adviser Mohammad Haneef Atmar had resigned, in a blow to the embattled unity government before parliamentary elections scheduled for October.

The palace announced later Sunday that Atmar had been replaced by Hamdullah Mohib, who was serving as Afghanistan’s ambassador to the United States.

“Accepting the resignation of a long-time friend and colleague was a difficult decision for me, but the decision had to be taken for the sake of the interest of the country,” said Ghani, according to a statement.

The Ghani administration has been widely criticised for its inability to counter an energised insurgency. The Taliban have intensified assaults on police and troops across the country and the Islamic State group has targeted the capital Kabul.

This month has seen an extraordinarily violent series of incidents, including an attack that saw the Taliban storm the provincial capital of Ghazni - just a two-hour drive from Kabul - despite repeated warnings from local officials that the city was in danger.

Militants held large parts of the city for days and Afghan forces needed US air power to push them back, resulting in widespread destruction and estimates of hundreds of deaths.

The resignation letters came a week after Ghani offered a conditional three-month ceasefire to the Taliban, a move welcomed by the United States and NATO after nearly 17 years of war.

The Taliban have yet to officially respond to the offer. A brief ceasefire in June had sparked hopes that a path for talks with the insurgents was opening.