pub trait KeyLifeCycle: KeyStore {
// Required methods
fn deprecate_key(&mut self, id: &KeyId) -> Result<()>;
fn revoke_key(&mut self, id: &KeyId) -> Result<()>;
fn cleanup_old_versions(
&mut self,
id: &KeyId,
keep_versions: usize,
) -> Result<Vec<KeyId>>;
}Expand description
Extended trait for advanced key lifecycle management
Provides methods for managing key states and cleanup policies
This exxtends KeyStore with operations for key deprecation and revocation
Required Methods§
Sourcefn deprecate_key(&mut self, id: &KeyId) -> Result<()>
fn deprecate_key(&mut self, id: &KeyId) -> Result<()>
Mark a particular key as deprecated (key should be able to decrypt but not encrypt)
Sourcefn revoke_key(&mut self, id: &KeyId) -> Result<()>
fn revoke_key(&mut self, id: &KeyId) -> Result<()>
Revoke a key (key should not be used for any operations)