Skip to main content

Crate bitwarden_importers

Crate bitwarden_importers 

Source
Expand description

§bitwarden-importers

Internal crate implementing format-specific vault importers for the Bitwarden SDK. Do not use directly.

Exposes client.importers() (ImporterClient) with:

  • import_kdbx — parses a KeePass KDBX (.kdbx) database (3.1 + 4, via the keepass crate), encrypts the entries for the user’s personal vault or a given organization, and submits them to the server’s import endpoint. Returns per-type counts.

§Keeper direct importer

The Keeper “direct” importer logs into Keeper’s API and decrypts the vault on-device. Its access layer is being ported from TypeScript (clients repo) into the keeper module incrementally (strangler-fig). The first piece, keeper::crypto, implements Keeper’s formats — unauthenticated AES-CBC (“aes-v1”), AES-GCM with a prepended nonce (“aes-v2”), an ECDH-P256 → SHA-256 → AES-GCM scheme, and Keeper’s custom encryptionParams blob. These are not Bitwarden cryptography and deliberately do not live in bitwarden-crypto; Use the RustCrypto crates. The crypto is currently internal Rust with no WASM / UniFFI bindings — the low-level primitives are deliberately not exposed across the FFI boundary. Platform bindings will be created once the structured access layer (records, folders, the sync-down protobuf) is ported, so the exposed surface can be record/folder-level operations rather than raw byte arrays.

§Architecture

The shared “interchange” model (ImportingCipher, CipherType, Login/Card/…, and the From<ImportingCipher> for CipherView bridge plus encrypt_import) lives in bitwarden-exporters and is reused here — this crate depends on bitwarden-exporters. CXF import remains in bitwarden-exporters because it is one half of a bidirectional codec.

Modules§

error 🔒
import 🔒
Routing: maps each importer’s public entry to its parser + the generic submit pipeline.
importer_client 🔒
importers 🔒
Format-specific importer parsers. Each parser turns its file format into a crate::pipeline::ParsedImport; the generic pipeline encrypts and submits it.
onepassword_access
The 1Password access module: log in to an account and download its vaults.
pipeline 🔒
Generic submit pipeline shared by all SDK importers.
uniffi_support 🔒

Structs§

CipherTypeCount
Number of imported ciphers of a given type.
ImportOptions
Destination options for a vault import.
ImportSummary
Counts of what an import submitted to the server, broken down by cipher type so the client can render its per-type result table.
ImportTargetCollection
An existing organization collection to assign an org import to.
ImportTargetFolder
An existing personal folder to nest a personal import under.
ImporterClient

Enums§

ImportError

Constants§

UNIFFI_META_CONST_BITWARDEN_IMPORTERS_RECORD_CIPHERTYPECOUNT 🔒
UNIFFI_META_CONST_BITWARDEN_IMPORTERS_RECORD_IMPORTOPTIONS 🔒
UNIFFI_META_CONST_BITWARDEN_IMPORTERS_RECORD_IMPORTSUMMARY 🔒
UNIFFI_META_CONST_BITWARDEN_IMPORTERS_RECORD_IMPORTTARGETCOLLECTION 🔒
UNIFFI_META_CONST_BITWARDEN_IMPORTERS_RECORD_IMPORTTARGETFOLDER 🔒
UNIFFI_META_CONST_NAMESPACE_BITWARDEN_IMPORTERS 🔒
Export namespace metadata.

Traits§

ImporterClientExt