Definitions of habeas corpus
a legal remedy against being wrongly imprisoned; an order which states that a person in prison must appear before a court of law before they can be forced by law to stay in prison
The ruling gave Guantanamo prisoners the long-standing habeas corpus right to challenge their detention in US civilian courts.