Even though cougars are protected in CA they’d have a hard time prosecuting you for shooting one that was attacking pets or livestock on your property.
Last year there was a cougar along the front country between Glendora and the Pasadena area that killed several pets. Finally it was spotted one night in Arcadia and the Arcadia police killed it.
That's great news. :-)