The two firms say they identified weaknesses in security systems and disclosed this to the National Security Agency.