Trait libsignal_service::master_key::MasterKeyStore

source ·
pub trait MasterKeyStore {
    // Required methods
    fn fetch_master_key(&self) -> Option<MasterKey>;
    fn fetch_storage_service_key(&self) -> Option<StorageServiceKey>;
    fn store_master_key(&self, master_key: Option<&MasterKey>);
    fn store_storage_service_key(&self, storage_key: Option<&StorageServiceKey>);
}
Expand description

Storage trait for handling MasterKey and StorageKey.

Required Methods§

source

fn fetch_master_key(&self) -> Option<MasterKey>

Fetch the master key from the store if it exists.

source

fn fetch_storage_service_key(&self) -> Option<StorageServiceKey>

Fetch the storage service key from the store if it exists.

source

fn store_master_key(&self, master_key: Option<&MasterKey>)

Save (or clear) the master key to the store.

source

fn store_storage_service_key(&self, storage_key: Option<&StorageServiceKey>)

Save (or clear) the storage service key to the store.

Implementors§