Application for the writ shall be made by petition, signed and verified either by the plaintiff or by some person in his or her behalf, and shall specify:
(1) By whom the petitioner is restrained of his or her liberty, and the place where, (naming the parties if they are known, or describing them if they are not known).
(2) The cause or pretense of the restraint according to the best of the knowledge and belief of the applicant.
(3) If the restraint be alleged to be illegal, in what the illegality consists.