KeychainUnavailableException

Secure persistence failed or is unavailable for the current platform, session, or environment (for example: a headless Linux session with no Secret Service, or an Android call made without a Context). Error messages never include credentials.

This is distinct from a null read result: null means the key is genuinely absent, while this exception means the backend could not complete the operation.

The constructor is public so that test fakes of CredentialKeychain can simulate backend failures.

Constructors

Link copied to clipboard
constructor(reason: KeychainUnavailableException.Reason, message: String, cause: Throwable? = null)

Types

Link copied to clipboard

Properties

Link copied to clipboard

the failure category; use it to decide whether to retry, prompt the user, or clear the store.