King & Spalding can continue to defend a surveillance technology firm accused of deploying malware targeted at WhatsApp Inc. users after a federal judge blocked the Facebook subsidiary’s attempt to boot the firm from the case.

In an order Tuesday, U.S. District Chief Judge Phyllis Hamilton of the Northern District of California denied WhatsApp’s motion to disqualify King & Spalding from representing NSO Group Technologies, finding that WhatsApp did not demonstrate that the law firm still has access to confidential material, or even that the material is substantially related to the new case.