A person who violates this subsection is guilty of a class C felony.
It is unlawful for any person to willfully, as defined in section 12.1-02-02, possess a controlled substance or a controlled substance analog unless the substance was obtained directly from, or pursuant to, a valid prescription or order of a practitioner while acting in the course of the practitioner's professional practice, or except as otherwise authorized by this chapter, but any person who violates section 12-46-24 or 12-47-21 may not be prosecuted under this subsection.
N.D.C.C. § 19-03.1-23