Whenever any criminalist, questioned document examiner, latent print analyst, polygraph examiner employed by the Department of Justice, a police department, a sheriff's office, or a district attorney's office, an intelligence specialist or other technical specialist employed by the Department of Justice, a custodial officer employed in a local detention facility, or an employee of the county welfare department or the department which administers the county public social services program, is a witness before any court or magistrate in any criminal action or proceeding in connection with a matter regarding an event or transaction which he or she has perceived or investigated in the course of his or her official duties, where his or her testimony would become a matter of public record, and where he or she is required to state the place of his or her residence, he or she need not state the place of his or her residence, but in lieu thereof, he or she may state his or her business address, unless the court finds, after an in camera hearing, that the probative value of the witness's residential address outweighs the creation of substantial danger to the witness.
Nothing in this section shall abridge or limit a defendant's right to discover or investigate this information. This section is not intended to apply to confidential informants.
Ca. Pen. Code § 1328.6