CryptoSetupExtension extension

on

Methods

getCryptoIdentityState() Future<({bool connected, bool crossSigningEnabled, bool initialized, bool keyBackupEnabled})>

Available on Client, provided by the CryptoSetupExtension extension

Returns the current state of the crypto identity.
initCryptoIdentity({String? passphrase, String? reuseExistingStorageRecoveryKeyOrPassphrase, String? keyIdentifier, bool selfSign = true, bool wipeSecureStorage = true, bool wipeKeyBackup = true, bool wipeCrossSigning = true, bool setupMasterKey = true, bool setupSelfSigningKey = true, bool setupUserSigningKey = true, bool setupOnlineKeyBackup = true, String? keyName}) Future<String>

Available on Client, provided by the CryptoSetupExtension extension

Bootstraps a crypto identity for the client. Creates secret storage and cross-signing keys and optionally online key backup. Returns the recovery key for the secret storage key in use — newly generated, or the existing key when reuseExistingStorageRecoveryKeyOrPassphrase is set.
restoreCryptoIdentity(String keyOrPassphrase, {String? keyIdentifier, bool selfSign = true}) Future<void>

Available on Client, provided by the CryptoSetupExtension extension

Reconnects to an already initialized crypto identity using the provided recovery key or passphrase. Throws if encryption is unavailable, the identity is not initialized, or it is already connected.