(a) Except as provided by Subsection (b), a state agency may not, without written consent, disseminate to any person the personal identifying information of a person who submits information to the state agency for the purpose of obtaining an occupational license.
(b) A state agency may disseminate information described by Subsection (a) with respect to a person without the person's written consent if the dissemination is:
(1) required or permitted by a federal statute or by another law of this state; or
(2) made by or to a law enforcement agency for a law enforcement purpose.
(c) A state agency shall retain the written consent of a person obtained as required under this section in the state agency's records.
(d) For purposes of this section, the term "occupational license" does not include a license or permit that is administered by the comptroller under the Occupations Code.