No licensee or any employee of such licensee shall divulge to any such license shall divulge to any person, except as otherwise provided by law, other than to his principal or his employer any information acquired as a result of any investigation, surveillance, or other employment performed by such licensee or employee. Provided, however, that the provisions of this section shall not apply to any employer who is also the holder of a license issued pursuant to this chapter who has the written consent of the client or principal to divulge any information falling within the terms of this section, and further provided, that the provisions of this section will not apply to the taking of testimony or the receiving of evidence in any judicial proceeding. Any person violating this section or any employee who shall willfully make a false report to his employer concerning his employment or work shall be guilty of a misdemeanor and shall be punished as provided by law.