You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Store the dcd_... device token encrypted, as agreed (variant A):
Key: AndroidKeyStore, AES-256-GCM, 12-byte IV generated randomly by the Keystore. No setUserAuthenticationRequired and no setUnlockedDeviceRequired, because the background sync needs the key. StrongBox is tried first, falling back to the hardware or software Keystore.
File: in noBackupFilesDir, written via AtomicFile. It is excluded from backups, in addition to allowBackup="false".
Format: IV ‖ ciphertext. The associated data is a fixed context string plus the format version.
If the key is missing or decryption fails (for example after a restore or a Keystore reset), the state is treated like a 401: the device has to be re-paired. The event buffer is kept. There is no retry loop.
The token is never logged.
Threat model: this protects against file extraction (backups, ADB on unrooted devices, disk images, other apps). It does not protect against root or against malware running under the app's UID. A student who roots their own device can extract the token.
Activity