and the USG is ordered to take "all necessary and appropriate diplomatic steps to facilitate the release."

Here we have a story of extraordinary rendition, barbaric conditions of imprisonment, and very enhanced interrogations leading to false confessions - all taking place in Astan and verified by uncontested testimony.

Torture, delay may end “enemy” status
Monday, June 22nd, 2009 8:18 pm | Lyle Denniston

In a significant legal breakthrough for Guantanamo Bay prisoners, the federal judge who has previously upheld the broadest detention power for the government ruled on Monday that torture of an individual and the passage of time after he had ties to terrorism can end his status as an enemy of the United States, and require his release.

U.S. District Judge Richard J. Leon, ruling in the case of a Syrian national who had links to Al Qaeda in Afghanistan years ago, ruled that the prisoner could no longer be detained as an “enemy combatant,” and the government must make efforts to release him “forthwith.” ....
No doubt the acts proved were war crimes, the individuals who committed them are war criminals, and their organization can be fairly found to be a criminal enterprise. However, do not expect any prosecutions of the individuals or the organization - which is named al-Qaeda.

The facts from Judge Leon's public opinion (a longer classified opinion is sealed) are interesting:

(pp. 2, 7-8)

Petitioner Janko, a Syrian citizen who spent his teen years in the United Arab Emirates, was taken into custody by U.S. forces in January 2002 in Kandahar, Afghanistan. (Unclassified Return ~~ 1-2, 19 [Dkt. #117]; Unclassified Traverse at 81-82, 92 [Dkt. # 151].) Initially he was held and questioned at Kandahar Air Base, until he was ultimately taken to Guantanamo Bay, Cuba, after approximately 100 days. (Unclassified Return ~ 42, n.12; Unclassified Traverse at 2.)
....
The Government contends, in essence, that petitioner Janko is an enemy combatant because he was "part of ... Taliban or al Qaeda forces" at the time he was taken into custody by U.S. forces in 2002. In particular, the Government argues that petitioner Janko: (1) traveled to Afghanistan to participate in jihad on behalf of the Taliban; (2) stayed for several days at a guesthouse used by Taliban and al Qaeda fighters and operatives in early 2000, where he helped clean some weapons; and (3) thereafter attended the al Farouq training camp for a brief period of time. (Unclassified Return ~~ 27-30,32-40; Unclassified Oral Arg. Tr. 21-27.) The Government effectively concedes, however, that petitioner Janko was not only imprisoned, but tortured by al Qaeda into making a false "confession" that he was a U.S. spy, and imprisoned thereafter by the Taliban for over eighteen months at the infamous Sarpusa prison in Kandahar. [3] (Unclassified Return ~ 42; Unclassified Traverse at 13-15, 84-86.)

[3] Petitioner Janko contends, and the Government does not dispute, that the conditions in the Sarpusa prison were so terrible - if not horrific - that many prisoners died while incarcerated. Prisoners were fed next to nothing, and the prison was overcrowded, unsanitary, and lacked sufficient medical care. (Unclassified Traverse at 86; Unclassified Traverse Ex. 4, ~ 37; Unclassified Traverse Ex. 12, ~ 3.)

Notwithstanding these extraordinary intervening events, the Government contends that Janko was still "part of' the Taliban and/or al Qaeda when he was taken into custody after U.S. forces learned from a reporter of petitioner's presence at the abandoned prison in January 2002. [4](Unclassified Oral Arg. Tr. 9, 31; Unclassified Traverse at 86-92.)

[4] Originally, the Government and the U.S. media mistook Janko as one of a number of suicide martyrs based on videotapes captured at an al Qaeda safehouse. (Unclassified Oral Arg. Tr. 12-13; Unclassified Traverse at 92-93.) The tape involving Janko, however, was actually an al Qaeda torture tape. (Unclassified Oral Arg. Tr. 12-13; Unclassified Traverse at 2.) Nevertheless, upon debriefing and interrogating Janko, the Government came to realize he had had a preexisting relationship with al Qaeda prior to his incarceration by the Taliban. (Unclassified Return ~~ 1,42 n.12.)
Such was the DoJ's case. The detainee's case added some more facts:

(pp.8, 8-9)

Petitioner, not surprisingly, disagrees. He denies going to Afghanistan to participate in jihad and, while he admits to staying briefly at a Taliban guesthouse, he claims he did so against his will. (Unclassified Oral Arg. Tr. 6, 18; Unclassified Traverse at 44.) Moreover, he contends that he was later taken "involuntarily" to the al Farouq training camp, fearing that he would be killed if he did not comply. (Unclassified Oral Arg. Tr. 6, 18; Unclassified Traverse at 46-48.) While there he claims he received no more than small arms training and asked to leave on his eighteenth day in residence. (Unclassified Oral Arg. Tr. 18; Unclassified Traverse at 49.) Finally, he claims that he was accused by al Qaeda leaders of being a spy and was tortured [5] repeatedly by al Qaeda for three months until he gave a false "confession" to being a U.S. spy. (Unclassified Oral Arg. Tr. 7, 18; Unclassified Traverse at 84-86.)

[5] Although a detailed description ofthe various torture methods the petitioner was subjected to by al Qaeda is beyond the scope of this opinion, it would be fair to say that if his account is true even in part, al Qaeda's conduct would be fairly characterized as barbaric.

In addition, petitioner stresses, and the Government does not dispute, that by the point in time he was taken into U.S. custody in 2002 he was a free man that had been left behind in late 2001 at the Sarpusa prison with thousands of Northern Alliance prisoners. (Unclassified Oral Arg. Tr. 5-8,20; Unclassified Traverse at 86-92.) Thus, petitioner contends, in essence, that even if he had had a prior relationship with al Qaeda or the Taliban in 2000, his subsequent torture and imprisonment for eighteen months vitiates that relationship to such a degree that he no longer was "part of" al Qaeda or the Taliban when he was taken in custody in 2002. The Government disagrees.
Such was the detainee's case.

Judge Leon's analysis of this evidence is a bit long to quote (pp.9-12), but it starts and ends with:

By taking a position that defies common sense, the Government forces this Court to address an issue novel to these habeas proceedings: whether a prior relationship between a detainee and al Qaeda (or the Taliban) can be sufficiently vitiated by the passage of time, intervening events, or both, such that the detainee could no longer be considered to be "part of" either organization at the time he was taken into custody. The answer, of course, is yes. Accordingly, the question before the Court today is whether that is exactly what happened in this case. For the following reasons, I believe it is.
....
Thus, combining the limited and brief nature of Janko's relationship with al Qaeda (and/or the Taliban), with the extreme conduct by his captors over a prolonged period of time, the conclusion is inescapable that his preexisting relationship, such as it was, was sufficiently vitiated that he was no longer "part of' al Qaeda (or the Taliban) at the time he was taken into custody by U.S. forces in 2002. Accordingly, the Government has failed to establish by a preponderance of the evidence that Janko was lawfully detainable as an enemy combatant under the AUMF at the time he was taken into custody, and the Court must, and will, GRANT his petition for a writ of habeas corpus and order the Government to take all necessary and appropriate diplomatic steps to facilitate his release forthwith.
This case (so far) is unique - comparable to the case of the Taliban informant who was also ordered to be released under the same conditions.