Skip to main content
Be Bitwise

Certificate Deployment & Authentication

Mobile Enterprise & MDM Security · Mobile Advanced Security track

10 min read

In this module

Certificates in Enterprise Mobile Security

Passwords are the soft underbelly of enterprise mobility. Phishable, brute-forceable, shared between teammates, dumped on the dark web. Certificate-based authentication swaps passwords for cryptographic proof — the device demonstrates its identity by performing a private key operation that only it can do, using a key locked in tamper-resistant hardware.

Hand-rolling certificates onto thousands of devices isn't going to happen. This lesson covers the protocols and architecture that automate the job.

SCEP: Automated Certificate Provisioning

The Simple Certificate Enrollment Protocol (SCEP) automates requesting, issuing, and installing certificates on mobile devices. It's the workhorse here.

How SCEP Works

  1. The MDM pushes a SCEP configuration profile to the device containing: the SCEP server URL, a one-time challenge password (or dynamic challenge from the MDM), and the CA certificate.
  2. The device generates an asymmetric key pair. On Android the key can be generated in the TEE or StrongBox. On iOS the SCEP payload produces an RSA key in software, because the Secure Enclave only handles P-256 elliptic-curve keys; for a hardware-bound, attested key on Apple devices you want the ACME payload (iOS 16 and later) instead.
  3. The device creates a Certificate Signing Request (CSR) containing the public key and device identity information.
  4. The device submits the CSR and challenge password to the SCEP server over HTTPS.
  5. The SCEP server validates the challenge and forwards the CSR to the Certificate Authority.
  6. The CA signs the certificate and returns it through the SCEP server.
  7. The device installs the signed certificate.

Security Considerations

  • Challenge password: The one-time challenge prevents unauthorised devices from requesting certificates. Dynamic challenges (generated per-device by the MDM) are more secure than static shared challenges.
  • Key attestation: SCEP itself carries none. On Android, a DPC can generate the key in the TEE or StrongBox and get Android key attestation for it; on Apple devices, attested hardware-bound keys come from the ACME payload instead, as the next diagram shows.
  • Certificate renewal: SCEP supports automatic renewal before certificate expiry, preventing service interruptions.

Compare SCEP's flow above with Apple's ACME payload on iOS 16 and later. In SCEP the server's only evidence is the challenge password, which says nothing about where the key lives. ACME's device-attest-01 challenge instead asks Apple to vouch for the device and for a key generated inside its Secure Enclave:

Only the second flow lets the server prove the private key never left the hardware. A stolen SCEP challenge, by contrast, gets a certificate issued to any machine at all.

Try spotting the weakness in each of these before you open the answer.

xml
<!-- A: iOS SCEP payload, pushed to every enrolled device -->
<key>Challenge</key>
<string>Welcome2024!</string>
xml
<!-- B: Android Network Security Config in the corporate VPN app -->
<base-config>
<trust-anchors>
<certificates src="system" />
<certificates src="user" />
</trust-anchors>
</base-config>
text
C: the expense app's backend accepts an OIDC ID token when
- the signature verifies against the IdP's published keys
- iss == https://login.corp.example
- exp is in the future
Show the answer

A is a static challenge shared by every device, and probably sitting in a profile someone emailed around. Anyone who reads it can request a certificate from the SCEP server. SCEP has no proof that the requester is an enrolled device beyond that challenge, which is why per-device dynamic challenges matter. B trusts user-installed CAs, so anyone who can talk the user into installing a certificate can intercept the VPN app's own TLS. C never checks aud. A valid token the same IdP issued to any other app, including one an attacker registered, gets accepted by the expense backend.

Per-App VPN

Old-school VPN shoves every packet from the device through the corporate network. On a BYOD phone that's a privacy disaster — personal browsing routed through your employer — and a bandwidth tax to boot.

Per-app VPN narrows the tunnel to specific managed apps. Their traffic goes through the corporate VPN; everything else takes the normal network path.

Platform Implementation

  • iOS: Per-app VPN comes from an MDM profile that pairs managed apps with a VPN configuration. A managed app fires a network request, iOS spins up the tunnel automatically. When the app backgrounds, the tunnel can drop.
  • Android: Per-app VPN runs through the VpnService API with addAllowedApplication(). Only the listed apps' traffic enters the tunnel; everything else goes around it.

Always-On VPN

For fully managed devices, always-on VPN sends every packet through the corporate network. Tunnel drops, network drops with it (lockdown mode). The guarantee: corporate data never crosses an unprotected wire.

Single Sign-On (SSO) on Mobile

SSO lets a user authenticate once, then access a stack of corporate apps without typing credentials again. On mobile, the SSO machinery rides on broker apps and federated auth protocols.

SAML and OIDC

SAML (Security Assertion Markup Language) and OIDC (OpenID Connect) are the standard federated authentication protocols:

  • The user launches a corporate app.
  • The app redirects to the Identity Provider (IdP) - Azure AD, Okta, Ping Identity.
  • The user authenticates with the IdP (once per session).
  • The IdP issues an assertion (SAML) or tokens (OIDC) to the app.
  • The app grants access based on the assertion/tokens.

Broker Apps

Broker apps (Microsoft Authenticator, Intune Company Portal on Android, Okta Verify) sit at the centre of the device's authentication story:

  • The broker holds the SSO session token.
  • When any corporate app needs authentication, it delegates to the broker.
  • The broker provides the authentication token without requiring the user to re-enter credentials.
  • The broker can enforce additional security checks: device compliance, biometric verification, PIN.

User authenticates to the broker once. Every other corporate app rides that single SSO session.

SSO Session Security

The SSO broker session is the most sensitive credential on the device. If an attacker compromises the broker's session token, they gain access to every corporate application. This is why broker apps store tokens in hardware-backed keystores (Secure Enclave, StrongBox), require biometric verification for token access, support device compliance checks before issuing tokens, and implement token binding to prevent token theft and replay.

Conditional Access

Conditional Access glues the MDM compliance engine to the identity provider. Before granting access to anything corporate, the system checks the device against a policy gate.

Decision Flow

Typical Compliance Checks

  • MDM enrolment: Is the device enrolled and managed?
  • OS version: Is the OS version above the minimum? Are security patches current?
  • Encryption: Is device encryption enabled?
  • Jailbreak/root: Has the device been compromised?
  • App compliance: Are required security apps installed? Are banned apps absent?
  • Location: Is the device accessing from an expected geography?

Non-compliant devices get a denial and remediation steps — update the OS, enable encryption, re-enrol. Compliance comes back, access comes back, no helpdesk ticket required.

Zero Trust on Mobile

Zero Trust starts from a simple premise: nothing gets a free pass. No device, no user, no network. Every access request is verified continuously, wherever the request comes from.

Continuous Verification

Old-school security models authenticate once and trust forever. Zero Trust on mobile asks for more:

  • Device posture assessment: Every access request checks current device compliance (not just at login).
  • User behaviour analysis: Anomalous behaviour (unusual location, unusual app access patterns, unusual time) triggers re-authentication or access denial.
  • Micro-segmentation: Users access only the specific resources they need, not the entire corporate network.
  • Session re-evaluation: Access tokens have short lifetimes and are continuously re-evaluated against current compliance state.

FIDO2/WebAuthn on Mobile

FIDO2 (Fast Identity Online 2) and WebAuthn are the phishing-proof standards. Public-key crypto, no shared secrets to lift.

Platform Authenticators

Modern phones ship with hardware-backed platform authenticators:

  • iOS: The platform authenticator handles FIDO2, gated by Face ID or Touch ID. Passkeys are synced through iCloud Keychain, so their private keys are protected by the Secure Enclave and iCloud Keychain's end-to-end encryption rather than generated once and locked inside one Enclave. Managed devices can be given device-bound passkeys instead through declarative device management.
  • Android: Passkeys saved to Google Password Manager are likewise synced, end-to-end encrypted, between the user's devices, gated by biometric or screen lock. Hardware-bound keys in the TEE or StrongBox are what you get from security keys and some enterprise authenticator apps.

How FIDO2 Prevents Phishing

Passwords get typed into phishing pages all day long. FIDO2 credentials are bound to the origin — the domain name. The authenticator inspects the requesting domain before signing the challenge. A phishing page at evil-bank.com can't unlock credentials registered for real-bank.com; the origins don't match and the authenticator refuses.

Origin binding, hardware key storage, biometric gating — stack them and FIDO2 is the strongest authentication you'll find on a phone. One catch for enterprise policy: consumer passkeys on both platforms sync through iCloud Keychain or Google Password Manager, so they aren't tied to one device's hardware. If policy demands device-bound credentials, check which kind you're actually getting.

Key Concept
Certificate and Zero-Trust Authentication

Enterprise mobile authentication is moving from passwords to certificates (SCEP-provisioned, hardware-backed) and FIDO2/WebAuthn (origin-bound, phishing-resistant). Conditional Access ensures only compliant devices can access corporate resources. Per-app VPN isolates corporate traffic from personal traffic. Together, these mechanisms implement Zero Trust on mobile: continuous verification of device posture, user identity, and application compliance for every access request, with no implicit trust based on network location or previous authentication.