It’s basically impossible for an American company to defy the American government. They can try in court but ultimately the government has F-22s and nuclear weapons and Apple does not.
It's definitely not common, but it happens.
They don't need to use weapons to spy on citizens. The constitutional right to privacy was stripped in the Bush era and it's been open season ever since.