(a) Unless inconsistent with AS 11.81.320 - 11.81.410, conduct which would otherwise constitute an offense is justified when it is required or authorized by law or by a judicial decree, judgment, or order.
(b) The justification afforded by this section also applies when
(1) the person reasonably believes the conduct to be required or authorized by a decree, judgment, or order of a court of competent jurisdiction or in the lawful execution of legal process, notwithstanding lack of jurisdiction of the court or defect in the legal process; or
(2) the person reasonably believes the conduct to be required or authorized to assist a peace officer in the performance of the officer's duties, notwithstanding that the officer exceeded the officer's authority.