(a) If, after investigation, the commissioner has reasonable grounds to believe that a person has engaged or is about to engage in any act or practice constituting a violation of any provision of this division or any rule or order hereunder, the commissioner may bring an action to enjoin the acts or practices or to enforce compliance with this division or any rule or order adopted under this division. The action shall be brought in the name of the people of the State of California in the superior court. Upon a proper showing, a permanent or preliminary injunction, restraining order, or writ of mandate shall be granted. A receiver, monitor, conservator, or other designated fiduciary or officer of the court, which may include the commissioner, may be appointed for the defendant or the defendant's assets. Any other ancillary relief may be granted as appropriate. A receiver, monitor, conservator, or other designated fiduciary or officer of the court appointed by the superior court pursuant to this section may, with the approval of the court, exercise any or all of the powers of the defendant's officers, directors, partners, trustees, or persons who exercise similar powers and perform similar duties. The powers include the filing of a petition for bankruptcy. No action at law or in equity may be maintained by any party against the commissioner, or a receiver, monitor, conservator, or other designated fiduciary or officer of the court, by reason of their exercising these powers or performing these duties pursuant to the order of, or with the approval of, the superior court.