pub struct SessionKeys {
pub encryption: SymmetricKey,
pub privacy: SymmetricKey,
}Available on crate feature
rustcrypto only.Expand description
The keys one session protects its messages with.
The privacy key is derived from the encryption key once, at session establishment, rather than per message: it is a KDF call, and doing it on every send would be visible on a microcontroller.
Fields§
§encryption: SymmetricKeyThe AEAD key for this direction (§4.8).
privacy: SymmetricKeyThe AES-CTR key for header obfuscation (§4.9.1).
Implementations§
Source§impl SessionKeys
impl SessionKeys
Sourcepub fn from_encryption_key(encryption: SymmetricKey) -> Result<Self>
pub fn from_encryption_key(encryption: SymmetricKey) -> Result<Self>
Derives the privacy key from an encryption key (§4.9.1).
Trait Implementations§
Source§impl Clone for SessionKeys
impl Clone for SessionKeys
Source§impl Debug for SessionKeys
impl Debug for SessionKeys
impl Eq for SessionKeys
Source§impl PartialEq for SessionKeys
impl PartialEq for SessionKeys
impl StructuralPartialEq for SessionKeys
Auto Trait Implementations§
impl Forget for SessionKeys
impl Freeze for SessionKeys
impl Move for SessionKeys
impl RefUnwindSafe for SessionKeys
impl Send for SessionKeys
impl Sync for SessionKeys
impl Unpin for SessionKeys
impl UnsafeUnpin for SessionKeys
impl UnwindSafe for SessionKeys
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