#[repr(u16)]pub enum CiphertextVersion {
Latest = 0,
V1 = 1,
V2 = 2,
}
Expand description
The versions of the encryption scheme to use.
Variants§
Latest = 0
Uses the latest version.
V1 = 1
Uses version 1: AES256-CBC-HMAC-SHA2-256.
V2 = 2
Uses version 2: XChaCha20-Poly1305.
Trait Implementations§
Source§impl Clone for CiphertextVersion
impl Clone for CiphertextVersion
Source§fn clone(&self) -> CiphertextVersion
fn clone(&self) -> CiphertextVersion
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for CiphertextVersion
impl Debug for CiphertextVersion
Source§impl Default for CiphertextVersion
impl Default for CiphertextVersion
Source§impl From<CiphertextVersion> for u16
impl From<CiphertextVersion> for u16
Source§fn from(enum_value: CiphertextVersion) -> Self
fn from(enum_value: CiphertextVersion) -> Self
Converts to this type from the input type.
Source§impl PartialEq for CiphertextVersion
impl PartialEq for CiphertextVersion
Source§impl TryFrom<u16> for CiphertextVersion
impl TryFrom<u16> for CiphertextVersion
Source§type Error = TryFromPrimitiveError<CiphertextVersion>
type Error = TryFromPrimitiveError<CiphertextVersion>
The type returned in the event of a conversion error.
Source§impl TryFromPrimitive for CiphertextVersion
impl TryFromPrimitive for CiphertextVersion
const NAME: &'static str = "CiphertextVersion"
type Primitive = u16
type Error = TryFromPrimitiveError<CiphertextVersion>
fn try_from_primitive( number: Self::Primitive, ) -> Result<Self, TryFromPrimitiveError<Self>>
Source§impl Zeroize for CiphertextVersion
impl Zeroize for CiphertextVersion
impl Copy for CiphertextVersion
impl Eq for CiphertextVersion
impl StructuralPartialEq for CiphertextVersion
Auto Trait Implementations§
impl Freeze for CiphertextVersion
impl RefUnwindSafe for CiphertextVersion
impl Send for CiphertextVersion
impl Sync for CiphertextVersion
impl Unpin for CiphertextVersion
impl UnwindSafe for CiphertextVersion
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.