If a person comes into this state in obedience to a court order directing the person's attendance and testimony in a criminal action or grand jury investigation in this state the person shall not, while in this state, pursuant to such court order, be subject to arrest or the service of process, civil or criminal, in connection with matters which arose before entrance into this state under such order.
If a person passes through this state while going to another state in obedience to a court order requiring the person's attendance and testimony in a criminal action or grand jury investigation in that state or while returning therefrom, the person shall not, while so passing through this state, be subject to arrest or the service of process, civil or criminal, in connection with matters which arose before entrance into this state pursuant to such court order.
Minn. Stat. § 634.08
(9819-3) 1935 c 140 s 3; 1955 c 812 s 3; 1986 c 444