Companies and law enforcement agencies in California carefully tread between federal laws devised to catch undocumented workers and new state laws meant to protect them.