Skip to main content

KeypackageExt

Trait KeypackageExt 

Source
pub trait KeypackageExt {
    // Required methods
    fn make_ref(&self) -> Result<KeypackageRef, OpenMlsError>;
    fn cipher_suite(&self) -> CipherSuite;
    fn credential_type(&self) -> CredentialType;
    fn is_valid(&self) -> bool;
}
Expand description

Extensions on the KeyPackage type for nicer usage patterns.

Required Methods§

Source

fn make_ref(&self) -> Result<KeypackageRef, OpenMlsError>

Make a “fat” KeypackageRef from this Keypackage.

This is a fairly inexpensive operation.

Source

fn cipher_suite(&self) -> CipherSuite

Returns the ciphersuite associated this this key package.

Source

fn credential_type(&self) -> CredentialType

Returns the credential type associated with this key package.

Source

fn is_valid(&self) -> bool

Determines whether a keypackage is valid in the sense of the former client_valid_keypackages_count method.

In practice, this just checks whether its lifetime (if present) has expired or not.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§