The United States has handed to Pakistan three prisoners including a senior Taliban militant held in Afghanistan, as Washington rushes to empty its Afghan prison before losing the legal right to detain people there at the end of the year.

US forces captured Latif Mehsud, the former number two commander in Pakistan’s faction of the Taliban, in October 2013, in an operation that angered then Afghan president Hamid Karzai.

Mehsud, a Pakistani, and his two guards were secretly flown to Pakistan, two senior Pakistani security officials said. The US military confirmed it transferred three prisoners to Pakistan’s custody on Saturday, but would not reveal their identities.

“TTP senior commander Latif Mehsud who was arrested was handed over to Pakistani authorities along with his guards,” one Pakistani security official said. “They reached Islamabad.”

The transfers coincide with a visit by outgoing US Defence Secretary Chuck Hagel to Afghanistan.

They also follow a spate of US drone strikes against the Tehreek-e-Taliban Pakistan (TTP), or Pakistani Taliban, and al-Qaeda. On Saturday, the Pakistani military killed an al-Qaeda commander accused of plotting to bomb the New York subway. The TTP is separate but allied to the Afghan Taliban. Both work alongside al-Qaeda.

Transfers of prisoners coincide with visit by Defence Secretary

The US Embassy in Kabul said the three prisoners had been held at a detention centre near Bagram airfield, the largest US base in Afghanistan.The facility is believed to house several dozen foreign prisoners who the United States will no longer be allowed to keep in Afghanistan when the mission for the US-led force there ends later this month.

“We’re actually just going through and returning all the third-country nationals detained in Afghanistan to resolve that issue,” a US embassy spokeswoman said. The quandary over what to do with the detainees held at the prison north of Kabul has rekindled outrage over the US policy of rendition in the early phases of the Afghan war.

The fate of the remaining prisoners was undecided and they could be returned to their home countries, brought into the US legal system or to the Guantanamo Bay prison in Cuba, the commander of the detention centre said in September.

Taliban militants fired two rockets into the Bagram base on Saturday, damaging a building and a road, a spokesman for international coalition forces said. A message on a Taliban-linked Twitter account suggested that Hagel was the target. He was not at Bagram at the time of the attack.

Mehsud was snatched by US forces last year not far from Kabul.

At the time, Karzai’s spokesman told the Washington Post Mehsud was travelling with a convoy of Afghan intelligence officials who wanted to recruit him for peace talks, and that the US forcibly removed him.

Sign up to our free newsletters

Get the best updates straight to your inbox:
Please select at least one mailing list.

You can unsubscribe at any time by clicking the link in the footer of our emails. We use Mailchimp as our marketing platform. By subscribing, you acknowledge that your information will be transferred to Mailchimp for processing.