In a controversial 5-4 decision written by Justice Anthony Kennedy, the U.S. Supreme Court ruled today that the petitioners detained in Guantanamo Bay have the constitutional privilege of habeas corpus. The court also determined that the Detainee Treatment Act’s procedures for reviewing the detainees’ status was not an adequate and effective substitute for the habeas writ, and that section 7 of the Military Commissions Act is an unconstitutional suspension of the writ. (Read the decision.)

According to Kennedy, the writ may be suspended only when public safety requires it in times of rebellion or invasion. None of the cases cited by either side in this dispute, regarding the writ’s geographic scope at common law, was dispositive. The court also rejected the government’s reading of Eisentrager as formalistic and constricted.

Extraterritoriality questions, it stated, turn on “objective factors and practical concerns, not formalism.” The Constitution grants Congress and the President the power to acquire, dispose of, and govern territory, not the “power to decide when and where its terms apply.” The political branches may not “switch the Constitution on and off at will,” nor may they decide “what the law is.” (Let’s hope the political branches don’t ignore their co-equal obligation to interpret and apply the law.)

Due to the “exceptional circumstances” presented in this case—the “grave separation of powers issues” and that petitioners have been denied “meaningful access to a judicial forum for years”—the court will not remand the case back to the D.C. Circuit, but rather allow the petitioners to proceed with their habeas actions in the district court. And rather than offer a comprehensive summary of the actual procedures for adequate habeas, the court said that habeas entitles the detainee to a “meaningful opportunity to demonstrate that he is being held” and that the habeas court must have the power to order the “conditional release of an individual unlawfully detained.”

The court recognized that certain accommodations might be necessary to carry out the ruling, including, but not limited to, channeling the cases to a single federal district court and protecting sources and methods of intelligence gathering.

Chief Justice John Roberts wrote a scathing dissent, joined by Justices Antonin Scalia, Clarence Thomas and Samuel Alito, arguing that the court struck down the “most generous set of procedural protections ever afforded aliens detained by this country” without bothering to say what due process rights the detainees possess or how the statute fails to vindicate those rights, and before the statute was even allowed to be tested. The majority’s opinion was less about the detainees and all about the “control of federal policy regarding enemy combatants.”