Human rights campaigners have failed to persuade the UK's highest court to come to the aid of a 30-year-old Pakistani held without trial for more than eight years after being captured following the allied invasion of Iraq.
British-based human rights lawyers asked the Supreme Court to help free Yunus Rahmatullah after appeals to the High Court and the Court of Appeal ended in disappointment. But a panel of seven Supreme Court justices dismissed their latest appeal - by a 5-2 majority - after a hearing in London.
Judges heard that Rahmatullah was captured in Iraq in 2004 by British troops operating in an area under American control. He was handed to US forces who transferred him to Afghanistan, where he remains.
Legal charity Reprieve employed a piece of ancient English common law in a bid to end Rahmatullah's ordeal, and lawyers asked judges to grant "habeas corpus" relief. Habeas corpus - Latin for "you may have the body" - is a procedure which requires a court to examine the legality of a detention.
Reprieve and law firm Leigh Day & Co, which represents Rahmatullah and takes instructions from one of his relatives, said he was being held without trial by American forces at Bagram air base in Afghanistan but remained under UK control as part of a "memorandum of understanding" with the Americans.
They argued that the UK Government had the power to ask American authorities to free him. British ministers disagreed.
The challenge failed in the High Court in July last year but succeeded at the Court of Appeal in December, when three judges issued a writ of habeas corpus. But in February, appeal judges cancelled the release order after being told that US authorities were not going to "play ball" and that British ministers had "reached the end of the road".
Jamie Beagent, the lawyer at Leigh Day & Co representing Mr Rahmatullah, said: "Sadly, despite the fact that in international law Mr Rahmatullah remains a British detainee and the United States does not consider him a security threat, our client remains in detention at Bagram.
"The writ of habeas corpus now upheld by the Supreme Court failed to secure his release as the US failed to act on the writ and it was subsequently discharged.
"We will be drawing the Supreme Court's findings to the attention of the Metropolitan Police who are currently investigating our client's case in relation to offences under the Geneva Conventions Act 1957."