pub struct AdvancedKeyManager { /* private fields */ }Expand description
Advanced key manager for Phalanx groups
Implementationsยง
Sourceยงimpl AdvancedKeyManager
impl AdvancedKeyManager
Sourcepub async fn create_key_set(
&self,
group_id: [u8; 32],
identity: &Identity,
) -> Result<KeySet>
pub async fn create_key_set( &self, group_id: [u8; 32], identity: &Identity, ) -> Result<KeySet>
Create a new key set for a group
Sourcepub async fn rotate_keys(
&self,
group_id: [u8; 32],
reason: RotationReason,
) -> Result<u64>
pub async fn rotate_keys( &self, group_id: [u8; 32], reason: RotationReason, ) -> Result<u64>
Rotate keys for a group
Sourcepub async fn add_member(
&self,
group_id: [u8; 32],
identity: &Identity,
) -> Result<()>
pub async fn add_member( &self, group_id: [u8; 32], identity: &Identity, ) -> Result<()>
Add a new member to the key set
Sourcepub async fn remove_member(
&self,
group_id: [u8; 32],
member_id: [u8; 32],
) -> Result<()>
pub async fn remove_member( &self, group_id: [u8; 32], member_id: [u8; 32], ) -> Result<()>
Remove a member from the key set
Sourcepub async fn get_encryption_key(
&self,
group_id: [u8; 32],
) -> Result<SymmetricKey>
pub async fn get_encryption_key( &self, group_id: [u8; 32], ) -> Result<SymmetricKey>
Get current encryption key for a group
Sourcepub async fn get_decryption_key(
&self,
group_id: [u8; 32],
sequence: u64,
) -> Result<SymmetricKey>
pub async fn get_decryption_key( &self, group_id: [u8; 32], sequence: u64, ) -> Result<SymmetricKey>
Get decryption key for a specific sequence
Sourcepub async fn derive_key(
&self,
group_id: [u8; 32],
context: &str,
params: &[u8],
) -> Result<SymmetricKey>
pub async fn derive_key( &self, group_id: [u8; 32], context: &str, params: &[u8], ) -> Result<SymmetricKey>
Derive a specialized key for a specific context
Sourcepub async fn create_backup(&self, group_id: [u8; 32]) -> Result<BackupId>
pub async fn create_backup(&self, group_id: [u8; 32]) -> Result<BackupId>
Create a backup of the key set
Sourcepub async fn process_pending_operations(&self) -> Result<usize>
pub async fn process_pending_operations(&self) -> Result<usize>
Process pending operations
Sourcepub async fn get_usage_stats(&self, group_id: [u8; 32]) -> Result<KeyUsageStats>
pub async fn get_usage_stats(&self, group_id: [u8; 32]) -> Result<KeyUsageStats>
Get key usage statistics
Auto Trait Implementationsยง
impl !Freeze for AdvancedKeyManager
impl !RefUnwindSafe for AdvancedKeyManager
impl Send for AdvancedKeyManager
impl Sync for AdvancedKeyManager
impl Unpin for AdvancedKeyManager
impl !UnwindSafe for AdvancedKeyManager
Blanket Implementationsยง
Sourceยงimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Sourceยงfn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more