AuthMigration

Entry point for FR Authenticator data migration.

AuthMigration orchestrates the three-step pipeline that imports legacy FR Authenticator data, converts it to the new OATH and Push credential storage format, and cleans up the legacy files.

Migration pipeline

  1. Import — checks LegacyStorageProvider.isMigrationRequired; if true, calls LegacyStorageProvider.getMigrationData.

  2. Migrate — converts LegacyMechanism entries to com.pingidentity.mfa.oath.OathCredential and com.pingidentity.mfa.push.PushCredential objects and writes them to SQLite.

  3. Cleanup — calls LegacyStorageProvider.cleanUp to remove legacy SharedPreferences files and AndroidKeyStore entries.

The migration is idempotent: if no legacy data is found, or if migration has already run, the pipeline aborts cleanly without error. A kotlinx.coroutines.sync.Mutex ensures that concurrent calls to start do not execute the pipeline simultaneously.

Logging

All pipeline events are logged through logger, which defaults to Logger.STANDARD. Override it via the LegacyAuthenticationConfig DSL block:

AuthMigration.start(context) { logger = Logger.WARN }

See also

Properties

Link copied to clipboard

Logger used throughout the migration pipeline.

Functions

Link copied to clipboard
suspend fun start(context: Context, block: LegacyAuthenticationConfig.() -> Unit = {})

Executes the full authenticator migration pipeline.