Device security
The consumer SDK blocks protected operations when it detects root or jailbreak indicators. Handle DEVICE_COMPROMISED by stopping the flow and showing a device error. Detection is heuristic and can be bypassed; it is not attestation.
When the SDK checks
- Before login, session installation and registration-token updates.
- Before every Wollette API attempt, again after your provider supplies a proof, and before returning a successful result.
- During hosted-login token exchange and refresh.
- On Android: during payment preparation, NFC service restoration and every NFC command.
What happens on detection
The operation fails with non-retryable DEVICE_COMPROMISED. The SDK blocks further protected work and attempts local cleanup:
- Invalidates the registration OTP session and the consumer session.
- On Android, deletes payment keys and disarms NFC. iOS also attempts to delete consumer account keys.
- Refuses to save new sessions to its store.
- Keeps refusing protected work on later calls, including a later
login, and retries cleanup each time.
A storage failure can stop later deletion steps. On iOS, failure clearing the payment vault can prevent pending-wallet/session cleanup, while protected work remains blocked. Do not interpret the error as proof of complete deletion.
clear, clearRegistration and payment stop operations remain available for cleanup. Your app should stop the flow and show a device error. Do not retry login in a loop.
The SDK does not delete your developer key or anything in your app's storage. Handle your own secrets and session when you receive this error.
Tap to pay
Android's HCE service cannot throw to a contactless reader. If compromise is detected while restoring payment material or processing a command, it keeps presentation disabled and returns a technical APDU response. Your app observes DEVICE_COMPROMISED from SDK calls such as pay.
Detection scope
| Platform | Indicators |
|---|---|
| Android | Test-key builds, and known su, Superuser, Magisk, KernelSU and APatch paths |
| iOS | Known jailbreak paths including rootless /var/jb, and whether /private is writable |
No shell command is executed and no root prompt is shown. iOS Simulator and macOS skip detection so the SDK can be developed there. Android test-key emulator images may be blocked. There is no bypass switch.
Limits
These are local indicators, not device attestation. Hidden root, hooks or modified SDK binaries can evade them, as described in the OWASP MASTG guidance on root and jailbreak detection. Test on stock and on rooted or jailbroken devices before release. Server-side attestation would require a separate integration.
Reinstall detection and automatic Keychain cleanup after an iOS reinstall are not part of this policy.
Bluetooth and POS
Stop the separate iOS consumer Bluetooth client with await bleClient.stop() when handling compromise or leaving its screen. Its lifecycle is owned by your app.
POS uses the shared detector but has its own blocked state and cleanup. It clears its credentials/context/key while retaining the financial journal; it does not clear consumer storage. See POS recovery.