Static
openOpen a crypto store.
The created store will be based on IndexedDB if a store_name
is
provided; otherwise it will be based on a memory store and once the
objects is dropped, the keys will be lost.
store_name
- The name that should be used to open the IndexedDB
based database. If this isn't provided, a memory-only store will be
used. Note the memory-only store will lose your E2EE keys when the
StoreHandle
gets dropped.
store_passphrase
- The passphrase that should be used to encrypt the
store, for IndexedDB-based stores
Optional
store_name: stringOptional
store_passphrase: stringStatic
openOpen a crypto store based on IndexedDB, using the given key for encryption.
store_name
- The name that should be used to open the IndexedDB
based database.
store_key
- The key that should be used to encrypt the store, for
IndexedDB-based stores. Must be a 32-byte array.
A struct containing an open connection to a CryptoStore.
Opening the CryptoStore can take some time, due to the PBKDF calculation involved, so if multiple operations are being done on the same store, it is more efficient to open it once.