Purpose
SureMDM provides script-based controls that allow administrators to manage SureIDP certificate authentication behavior on Android devices. These controls help define whether a domain is allowed to authenticate using a certificate, explicitly blocked from doing so, or reset to its default authentication state.
Prerequisites
- Access to the SureMDM Web Console
- Android devices enrolled in SureMDM
- SureIDP certificate already available on the device
- Permission to create and apply Run Script jobs
Run Scripts
- Grant Certificate Authentication
Enables SureIdP certificate authentication for a specified domain and certificate alias.
#!suremdm
grantCert(domain, alias)
Parameters:
- domain: The target domain (e.g., example.com)
- alias: Certificate alias stored on the device
Example:
#!suremdm
grantCert(“example.com”, “sureidp_cert”)

- Deny Certificate Authentication
Explicitly blocks SureIdP certificate authentication for a given domain.
#!suremdm
denyCert(domain)
Example:
#!suremdm
denyCert(“example.com“)

- Clear Certificate Authentication State
Clears any granted or denied certificate authentication state for the specified domain.
#!suremdm
clearCert(domain)
Example:
#!suremdm
clearCert(“example.com“)

Steps
- On the SureMDM Console
- Navigate to Jobs > New Job > Android > Run Script.
- Enter a Job Name and in the Script prompt, enter the required script (grantCert, denyCert, or clearCert).
- Click Save to create the job.
- To Apply the Job to Devices – Navigate to the SureMDM Home page
- Select the required device(s) or device group.
- Click Apply (or Group Apply) and select the created Run Script job.
Expected Results
- grantCert allows SureIDP to authenticate with the specified domain using the defined certificate alias.
- denyCert prevents the specified domain from using SureIDP certificate-based authentication.
- clearCert removes any previously configured authentication rules for the domain and restores default behavior.
Conclusion
Using Run Script jobs in SureMDM, administrators can precisely control SureIDP certificate authentication behavior on Android devices. This provides flexibility to allow, block, or reset certificate-based authentication for specific domains based on organizational security requirements.
Need more help? Here’s how to get help from our experts