Module crypto

Source
Expand description

Mobile specific crypto operations

This module contains temporary code for handling mobile specific cryptographic operations until the SDK is fully implemented. When porting functionality from client the mobile clients should be updated to consume the regular code paths and in this module should eventually disappear.

StructsΒ§

DeriveKeyConnectorRequest
Request for migrating an account from password to key connector.
DerivePinKeyResponse
Request for deriving a pin protected user key
InitOrgCryptoRequest
Represents the request to initialize the user’s organizational cryptographic state.
InitUserCryptoRequest
State used for initializing the user cryptographic state.
MakeKeyPairResponse
Response from the make_key_pair function
UpdatePasswordResponse
Response from the update_password function
UserCryptoV2KeysResponse
Response for the make_keys_for_user_crypto_v2, containing a set of keys for a user
VerifyAsymmetricKeysRequest
Request for verify_asymmetric_keys.
VerifyAsymmetricKeysResponse
Response for verify_asymmetric_keys.

EnumsΒ§

AuthRequestMethod
Auth requests supports multiple initialization methods.
CryptoClientError
Catch all error for mobile crypto operations.
DeriveKeyConnectorError
EnrollAdminPasswordResetError
InitUserCryptoMethod
The crypto method used to initialize the user cryptographic state.

ConstantsΒ§

UNIFFI_META_CONST_BITWARDEN_CORE_ENUM_AUTHREQUESTMETHOD πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_ENUM_INITUSERCRYPTOMETHOD πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_DERIVEKEYCONNECTORREQUEST πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_DERIVEPINKEYRESPONSE πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_INITORGCRYPTOREQUEST πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_INITUSERCRYPTOREQUEST πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_MAKEKEYPAIRRESPONSE πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_UPDATEPASSWORDRESPONSE πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_USERCRYPTOV2KEYSRESPONSE πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_VERIFYASYMMETRICKEYSREQUEST πŸ”’
UNIFFI_META_CONST_BITWARDEN_CORE_RECORD_VERIFYASYMMETRICKEYSRESPONSE πŸ”’

FunctionsΒ§

derive_key_connector πŸ”’
Derive the master key for migrating to the key connector
derive_pin_key πŸ”’
derive_pin_protected_user_key πŸ”’
derive_pin_user_key πŸ”’
enroll_admin_password_reset πŸ”’
get_user_encryption_key πŸ”’
get_v2_rotated_account_keys πŸ”’
Gets a set of new wrapped account keys for a user, given a new user key.
initialize_org_crypto πŸ”’
Initialize the user’s organizational cryptographic state.
initialize_user_crypto πŸ”’
Initialize the user’s cryptographic state.
make_key_pair πŸ”’
make_v2_keys_for_v1_user πŸ”’
Creates the user’s cryptographic state for v2 users. This includes ensuring signature key pair is present, a signed public key is present, a security state is present and signed, and the user key is a Cose key.
update_password πŸ”’
verify_asymmetric_keys πŸ”’