pub struct EphemeralBundleBytes {
pub apke_dhakem_sk: [u8; 32],
pub apke_mlkem_sk: [u8; 2400],
pub apke_mlkem_pk: [u8; 1184],
pub metadata_sk: [u8; 32],
pub metadata_pk: [u8; 1216],
}Expand description
Byte representation of one ephemeral key bundle’s secret halves
Fields§
§apke_dhakem_sk: [u8; 32]§apke_mlkem_sk: [u8; 2400]§apke_mlkem_pk: [u8; 1184]§metadata_sk: [u8; 32]§metadata_pk: [u8; 1216]Implementations§
Source§impl EphemeralBundleBytes
impl EphemeralBundleBytes
Sourcepub const LEN: usize
pub const LEN: usize
Serialized length of
apke_dhakem_sk || apke_mlkem_sk || apke_mlkem_pk || metadata_sk || metadata_pk.
Sourcepub fn as_bytes(&self) -> Vec<u8> ⓘ
pub fn as_bytes(&self) -> Vec<u8> ⓘ
Serialize as
apke_dhakem_sk || apke_mlkem_sk || apke_mlkem_pk || metadata_sk || metadata_pk.
Sourcepub fn try_from_bytes(bytes: &[u8]) -> Result<Self, Error>
pub fn try_from_bytes(bytes: &[u8]) -> Result<Self, Error>
Deserialize from
apke_dhakem_sk || apke_mlkem_sk || apke_mlkem_pk || metadata_sk || metadata_pk bytes.
§Errors
Returns an error if the byte slice has the incorrect length.
Sourcepub fn from_bytes(bytes: &[u8; 4864]) -> Self
pub fn from_bytes(bytes: &[u8; 4864]) -> Self
Deserialize from
apke_dhakem_sk || apke_mlkem_sk || apke_mlkem_pk || metadata_sk || metadata_pk bytes.
Auto Trait Implementations§
impl Freeze for EphemeralBundleBytes
impl RefUnwindSafe for EphemeralBundleBytes
impl Send for EphemeralBundleBytes
impl Sync for EphemeralBundleBytes
impl Unpin for EphemeralBundleBytes
impl UnsafeUnpin for EphemeralBundleBytes
impl UnwindSafe for EphemeralBundleBytes
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