1. a. It shall be unlawful for any present or former officer or employee of the state to willfully or recklessly divulge or to make known in any manner whatever not provided by law to any person the amount or source of income, profits, losses, expenditures, or any particular thereof, set forth or disclosed in any income return, or to permit any income return or copy thereof or any book containing any abstract or particulars thereof to be seen or examined by any person except as provided by law.

 b. It shall be unlawful for any person to willfully or recklessly print or publish in any manner whatever not provided by law any income return, or any part thereof or source of income, profits, losses, or expenditures appearing in any income return.
 c. Any person committing an offense described in this subsection shall be guilty of a serious misdemeanor. If the offender is an officer or employee of the state, such person shall also be dismissed from office or discharged from employment.
 d. Nothing in this section shall prohibit turning over to duly authorized officers of the United States or tax officials of other states state information and income returns pursuant to agreement between the director and the secretary of the treasury of the United States or the secretary’s delegate or pursuant to a reciprocal agreement with another state.
 2. It is unlawful for an officer, employee, or agent, or former officer, employee, or agent of the state to willfully or recklessly disclose to any person, except as authorized in subsection 1 of this section, any federal tax return or return information as defined in section 6103(b) of the Internal Revenue Code. It is unlawful for a person to whom any federal tax return or return information, as defined in section 6103(b) of the Internal Revenue Code, is disclosed in a manner unauthorized by subsection 1 of this section to thereafter willfully or recklessly print or publish in any manner not provided by law any such return or return information. A person violating this subsection is guilty of a serious misdemeanor.
 3. a. Unless otherwise expressly permitted by section 8A.504, section 8G.4, section 11.41, section 96.11, subsection 6, section 421.17, subsections 22, 23, and 26, section 421.17, subsection 27, paragraph “k”, section 421.17, subsection 31, section 252B.9, section 321.40, subsection 6, sections 321.120, 421.19, 421.28, 421.59, 422.72, and 452A.63, this section, or another provision of law, a tax return, return information, or investigative or audit information shall not be divulged to any person or entity, other than the taxpayer, the department, or internal revenue service for use in a matter unrelated to tax administration.

 b. This prohibition precludes persons or entities other than the taxpayer, the department, or the internal revenue service from obtaining such information from the department, and a subpoena, order, or process which requires the department to produce such information to a person or entity, other than the taxpayer, the department, or internal revenue service for use in a nontax proceeding is void.
 4. The director may disclose the tax return of a partnership, limited liability company, or S corporation, any such return information, or any investigative information related to the return, to any person who was a partner, shareholder, or member of such an entity during any part of the period covered by the return.
 5. a. Prior to the record in an appeal or contested case being made available for public inspection, the department shall redact the following information from any pleading, exhibit, attachment, motion, written evidence, final order, decision, or opinion contained in that record:

 (1) A financial account number.
 (2) An account number generated by the department to identify an audit or examination.
 (3) A social security number.
 (4) A federal employer identification number.
 (5) The name of a minor.
 (6) A medical record or other medical information.
 (7) A return as defined in section 421.6.
 b. Upon a motion filed by the taxpayer, the department may redact from the record in an appeal or contested case any other information from a pleading, exhibit, attachment, motion, or written evidence, if the taxpayer proves by clear and convincing evidence that the release of such information would disclose a trade secret or be a clear, unwarranted invasion of personal privacy.
 c. Notwithstanding paragraph “a”, when making final orders, decisions, or opinions available for public inspection, the department may disclose the items in paragraph “a” if the department determines such information is relevant or necessary to the resolution or decision of the appeal or case.
 d. Except as described in paragraphs “a” and “b”, all information contained in a pleading, exhibit, attachment, motion, written evidence, final order, decision, opinion, and the record in an appeal or contested case is subject to examination to the extent provided by chapter 22.
 6. The director may disclose taxpayer identity information to the press and other media for purposes of notifying persons entitled to tax refunds when the director, after reasonable effort and lapse of time, has been unable to locate the persons.
 7. The department may permit, by rule, the disclosure of state tax information to a person a taxpayer has authorized to receive such state tax information, in the manner prescribed by the department.