v1.0.17-debug
Debug build. Crash-on-Confirm REGRESSION from v1.0.16 fixed (evidence-backed + JVM logic proof).
Root cause (confirmed by code + standalone proof):
- v1.0.16 rewrote CryptoManager.decryptField to hard-require a GCM blob and
decrypt unconditionally. But pre-persist provisioning (SyncManager.provision ->
OAuthTokenRefresher.ensureFreshToken -> EmailSyncEngine.testConnection) calls
decryptAuthConfig on the in-memory DRAFT account, whose passwordEncrypted is a
RAW password (AuthConfig.AppPassword), NOT a GCM blob. The hard require()/
decrypt() threw uncaught -> entire app crashed on Confirm.
Fix:
- decryptField now tolerates a raw value: not-valid-base64 -> return as-is;
<12 bytes -> return as-is; GCM decrypt fails -> return original. A genuine
persisted GCM blob still decrypts correctly. Never returns corrupted data. - Autodiscover still emits only 993/587 (never 465/143) from v1.0.16.
Runtime proof (JVM, standalone): raw short/long passwords preserved; genuine blob
decrypts; pre-fix versions crash with IllegalArgumentException / AEADBadTagException.
Still needs on-device verification: install, add account with mailcow app-password,
confirm IMAP connects.