Habeas Corpus, in the Federal Court, is a petition that claims that you are being detained against your US constitutional rights. To get a writ of habeas corpus, you must file a petition for a civil (not criminal) proceeding in either state or federal court.A Writ of Habeas Corpus is a civil proceeding that is available in both State and Federal Court to challenge the legality of imprisonment. A Writ of Habeas Corpus. The basis for such an application is DRL §70. The "Great Writ" of habeas corpus is a fundamental right in the Constitution that protects against unlawful and indefinite imprisonment. The writ of habeas corpus primarily acts as a writ of inquiry, issued to test the reasons or grounds for restraint and detention. A writ of habeas corpus requires that a person who is in custody be brought before a judge or court and that they be able to challenge that custody. Docket No.: 2009NA026180. Accordingly, this petition for a writ of habeas corpus is denied in its entirety.