(1) Any person not subject to this code who:
(a) Has been duly subpoenaed to appear as a witness or to produce books and records before a court-martial, military commission, court of inquiry, or any other military court or board, or before any military or civil officer designated to take a deposition to be read in evidence before such a court, commission, or board;
(b) Has been duly paid or tendered the fees and mileage of a witness at the rates allowed to witnesses attending the superior court of the state; and
(c) Willfully neglects or refuses to appear, or refuses to qualify as a witness or to testify or to produce any evidence which that person may have been legally subpoenaed to produce;
is guilty of an offense against the state.
(2) Any person who commits an offense named in subsection (1) of this section shall be tried before the superior court of this state having jurisdiction and jurisdiction is conferred upon those courts for that purpose. Upon conviction, such a person shall be punished by a fine of not more than five hundred dollars, or imprisonment for not more than six months, or both.
(3) The prosecuting attorney in any such court, upon the certification of the facts by the military court, commission, court of inquiry, or board, shall prosecute any person violating this section.