FILE PHOTO: A man walks past the front gate of the International Committee of the Red Cross (ICRC) office in Jalalabad province June 2, 2013. REUTERS/Parwiz

KABUL (Reuters) - The Taliban have reinstated a security guarantee in Afghanistan for the International Committee for Red Cross (ICRC), two months after withdrawing safe passage for the neutral humanitarian agency, the militant group and an ICRC official said on Friday.

A meeting in the Taliban’s Qatar-based political office between its leaders and agency officials ended with the renewal of a pact allowing the agency to continue to provide, and expand, medical aid to all parties harmed by warfare.

“The security agreement...is once again reinstated and calls on all mujahideen to grant access...and provide security for the personnel and equipment of this organization,” the Taliban said in a statement, referring to its members.

The Taliban leadership in Doha discussed the humanitarian situation and security concerns before renewing the pledge, said Andrea Catta Preta, the ICRC’s spokeswoman in the Afghan capital.

“We told the Taliban leaders about our support to all prisoners in Afghanistan jails, we explained our medical programs,” she added. “Finally, we reached an understanding.”

In August, the Taliban had accused the Red Cross of failing to provide adequate medical aid to prisoners on a hunger strike in Kabul’s Pul-e Charkhi prison and withdrew the security cover.

The decision forced the ICRC to suspend several emergency programs in Afghanistan, where it has had a presence for three decades and about 1,000 staff. Last year it scaled back operations after attacks killed seven of its staff.

The ICRC treats all parties harmed by warfare and does not take sides. It operates in Taliban-controlled areas with guarantees of safety and helps to repatriate bodies from both sides after fighting between the militants and the Afghan army.