Category filter
How to find the Code Requirement of an application on Mac
A code requirement is a constraint that the code must satisfy to consider it valid for some purpose. It specifies the conditions that the system must use to evaluate the code signature and determine if the code is safe to be trusted. If the code fails to satisfy the requirements during evaluation, the code signature validation fails.
You can include the code signature requirement and bundle ID for an app to allow access to protected user data. Specifying the bundle ID and code requirement enhances the security of the Privacy Preferences payload. You can fetch the code signature requirement for the app by running the codesign commands. The Execute Custom Script action lets you execute these commands as scripts from the Hexnode console.
Fetch Code Requirement of an app
Run this command to find the code requirement of an app installed on the Mac:
1 |
codesign -dr - "path/Bundle ID" |
For example:
1 |
codesign -dr - /System/Applications/Time\ Machine.app |
Replace the “path/Bundle ID” with the path or Bundle Identifier of the app. You can find the code requirement starting after the text “designated =>”