Integrity and Posture profiles (API)
Integrity and Posture parameters
Use these parameters in the JSON data structure when you apply the Integrity and Posture policy (POLICY_CODE_DEVICE_POSTURE) to the app with app-market/policy.
Device posture
android_min_version | Specifies the minimum-allowed version of Android that end users must have on their devices. Values: integers 14–26. These values correspond to the Android API level. (See http://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels). The default value is 23 (that is, Android 6.0, "Marshmallow"). |
ios_min_version | Specifies the minimum-allowed version of iOS that end users must have on their devices. Blue Cedar supports iOS 9 and later. |
device_pin_required | 1: The app requires a device-level PIN or password to be configured on the device. (Default.) 0: The app does not require a device-level PIN or password to be configured. |
jailbreak_detection | 1: Disables the app when the mobile device is compromised by jailbreaking or rooting. 0: Do not check for jailbreaking or rooting. (Default.) |
Integrity verification
block_on_tamper_detected | 1: Disables the app if files included in the app (the Blue Cedar injectable and the configured security policies) have been modified since the app was secured. 0: Do not disable the app even if modifications are detected. Report the list of tampered files to the gateway to allow the gateway to decide whether to connect or deny. |
protected_files | Specifies which files to verify:
|
integrity_p12 | Optional. A custom certificate (base64 encoded string) to verify that the app has not been tampered with since it was last signed. If a custom certificate is not provided, the policy console generates and uses a default certificate. |
integrity_p12_password | The password used to generate the custom certificate. |
Integrity and Posture API resources
To manage Integrity and Posture profiles:
- profile: Use type="device_posture" to create an Integrity and Posture profile. See example below.
- profile/catalog/{policytype}: Use "device_posture" for "{type}". GET returns an array of details for all policy profiles of the specified type.
- profile/{GUID}: Use the profile ID to specify a policy profile. GET returns details for the specified profile, PUT updates the details in the specified profile, and DELETE archives the profile.
- settings/device-posture-default-profile (settings/{policytype}-default-profile: POST sets one of the Integrity and Posture profiles as the default. GET returns the GUID of the current default profile. DELETE archives the current default.
To retrieve details for the policy:
- app-policy/{GUID} : Use the policy ID to specify a policy. GET returns details for the specified policy.
- app-policy/code/{code} : Use POLICY_CODE_DEVICE_POSTURE to specify the policy. GET returns details for the specified policy.
To secure apps with the Integrity and Posture policy:
- app-market/policy : Use the policy GUID to apply the policy to an app.
Creating a Integrity and Posture profile
This example creates an Integrity and Posture profile with the profile API, specifying all options.
Request
curl -k -v -L -b c.txt -c c.txt -X POST http://bc.qwe.com/mocana-app-control/rest/profile \
-F name="TestProfile" \
-F type="device_posture" \
-F desc="Default Profile" \
-F data="{\"jailbreak_detection\":\"1\",\"device_pin_required\":\"1\", \
\"android_min_version\":\"23\",\"ios_min_version\":\"9.3\", \
\"integrity_p12_password\":\"abc123\", \
\"integrity_p12\":\"MIIQeQIBAzCCED8GC....3zDgCAggA\", \
\"protected_files\":\"policy\",\"block_on_tamper_detected\":\"1\"}"
Response
{
"profiles": {
"profile_name": "sd",
"profile_type": "device_posture",
"data": {
"profile_data_stamp": "2018-02-02 18:49:48.0",
"profile_data": "{\"jailbreak_detection\":\"1\",
\"protected_files\":\"policy\",\"android_min_version\":\"14\",
\"ios_min_version\":\"9.0\",\"integrity_p12_password\":\"abc123\",
\"block_on_tamper_detected\":\"1\",
\"integrity_cert_thumbprint\":\"d2abc71385d742b9b6e179934424278552fd47ac7dd96b43ecf39d44b911170f30a944826819afe6f1f1827579be17e8539fd7505c45c356f9390394c01660ed\",\"integrity_p12\":\"MIIQeQIBAzCCED8GCSqGSIb3DQEHAaCCEDAEghAsMIIQKDCCBl8GCSqGSIb3DQEHBqCCBlAwggZMAgEAMIIGRQYJKoZIhvcNAQcBMBwGCiqGSIb3DQEMAQYwDgQIalv0zHFv/S4CAggAgIIGGAotNKV68XZwA2evcPlJLQIE9bO1aPCJ9z1Z2znjUlhBVl39Pw3x6aro4szej6SH7WhWhopSEzFiGgrA1PZ9Kuu/TcGQr3Te0ep0HSbG51NPU5hVH5zlWKPyJAULs94L/HVCcnsDSLQZLRSnnAor9XoGBF66af57JCaZb6ds4Poylhf+aVWzol0C7p7lDZuWlC4IsO3zGuRlCwV5ogxhGp0mqnE3hcydzzIm7ElnzX23/5cImWhCgK1mtCqoq0JJHvoqwx9VMkS3VGi/mcajyOSanoaJv66PCpqVo+AElYt3EjChn6Rz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0MDIsmh9WSgbuowzgNnae3kyTqoqs+dGn3r0/xFfh28R659ALzq+6HOih1GRhGPhaQoi02GBCu3q3b4HtHW6HFuEZal1a8I5MHmcZrwtUblDlYsIOsrAw9UE07aim6jFYShHEw6mEZ0H1ErPS0WEFi4N694Wqu4dDw9ignt/P2HirTl8AYCRgBozKjBgr+NyEI24CaQv73Ox3IEnJBK3EvwBRAFHqIl0EIScU+MYbckw/lbMXcjB3uhC5F27+ApsiUr0qygmzTQBHEkH5IM7YtF6INlmooHuf7yki2rl4uYT5Sv9va8Foa2RytOGEG1KXNgYDcCzva253vlWJhxMr+9vRZ+7rtpX9amofj2WS4uoA1Y27iRkoigr76cx2l+Q8SaB3Zt0gUXGQCJVep6YcBfzY9WkxT5DwBtP0Uwk7vC/NCfnrAqOhKL2YQewPC294QSj4FF1Efdyp7a6AZ8bsLSvjDnxROeHviI5M5dq/7gbfEevkMal1lfomRBef7ATNhv8FdDjXCp1rIlj/s5jOztkxJoLFxDVBoCHbaVAqcMa7t8XM/rCOVTH9Qkm34rFfzORbuYRZ8gXmKfm6mfyV8CVm6HbGjgpYTarizPv42xFtJ/z66/hoduGf9AR1g9PDRwjPCGGpT988rX8jquv4auw1mYVHD81cpkW7BT3ggLXoHw/9wcenOMJgp5jhYiKUHwvGpnMwXLztZMgMBay+1jNS3goOVr4oS2kmUfynMO2A/dVwO7EcQz4lHVbz2MSUwIwYJKoZIhvcNAQkVMRYEFACu24St/YvZiq4vp3Z0lpg5hvo4MDEwITAJBgUrDgMCGgUABBSX3tTllYdfFd5NHJTljxE+9MI4ZwQIk3SHgb/3zDgCAggA\"}",
"profile_data_id": "40a0a27b-520c-4edb-b4dc-57de6fb73854"
},
"profile_url": "https://localhost:8443/mocana-app-control/rest/profile/d3d37266-9606-45b7-865e-09528ccdd32c",
"profile_id": "d3d37266-9606-45b7-865e-09528ccdd32c",
"profile_desc": ""
},
"message": "",
"status": "OK"
}