pub struct PastEpochDeletion { /* private fields */ }Expand description
The input to MlsGroup::delete_past_epoch_secrets().
This struct can be used for manual deletion of past epoch secrets by the application.
An MlsGroup also applies automatic deletion of past epoch secrets by default.
For more information, see PastEpochDeletionPolicy and MlsGroup::set_past_epoch_deletion_policy().
These methods can be used by the application to set up time-based deletion schedules:
NOTE: Epoch secrets that were created using openmls=0.8.1 or earlier will not yet include a timestamp.
After migration, these may not always be deleted by applying a time-based PastEpochDeletion. Only if a new secret that does include a timestamp is added later, and it matches the time-based condition in the PastEpochDeletion, all earlier past epoch secrets without timestamps will be deleted, as well. However, otherwise, past epoch secrets without timestamps will not be affected by applying time-based PastEpochDeletions.
To manually delete all past epoch secrets without timestamps, see:
PastEpochDeletion::delete_all_without_timestamps()
Implementations§
Source§impl PastEpochDeletion
impl PastEpochDeletion
Sourcepub fn older_than_duration(duration: Duration) -> Self
pub fn older_than_duration(duration: Duration) -> Self
Delete all past epoch secrets older than a provided duration.
Sourcepub fn before_timestamp(timestamp: SystemTime) -> Self
pub fn before_timestamp(timestamp: SystemTime) -> Self
Delete all past epoch secrets before a provided timestamp.
Sourcepub fn delete_all_without_timestamps() -> Self
pub fn delete_all_without_timestamps() -> Self
Delete all past epoch secrets without timestamps.
NOTE: This will delete all past epoch secrets having the legacy format that does not include a timestamp.
Sourcepub fn delete_all() -> Self
pub fn delete_all() -> Self
Delete all past epoch secrets.
Sourcepub fn max_past_epochs(self, max_past_epochs: usize) -> Self
pub fn max_past_epochs(self, max_past_epochs: usize) -> Self
Set the number of max_past_epochs that should be kept, at most.
Auto Trait Implementations§
impl Freeze for PastEpochDeletion
impl RefUnwindSafe for PastEpochDeletion
impl Send for PastEpochDeletion
impl Sync for PastEpochDeletion
impl Unpin for PastEpochDeletion
impl UnsafeUnpin for PastEpochDeletion
impl UnwindSafe for PastEpochDeletion
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
§impl<T> Classify for T
impl<T> Classify for T
type Classified = T
fn classify(self) -> T
§impl<T> Declassify for T
impl<T> Declassify for T
type Declassified = T
fn declassify(self) -> T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more