Trait rustls::StoresClientSessions
[−]
[src]
pub trait StoresClientSessions { fn put(&mut self, key: Vec<u8>, value: Vec<u8>) -> bool; fn get(&mut self, key: &Vec<u8>) -> Option<Vec<u8>>; }
A trait for the ability to store client session data. The keys and values are opaque.
Both the keys and values should be treated as highly sensitive data, containing enough key material to break all security of the corresponding session.
Required Methods
fn put(&mut self, key: Vec<u8>, value: Vec<u8>) -> bool
Stores a new value
for key
. Returns true
if the value was stored.
fn get(&mut self, key: &Vec<u8>) -> Option<Vec<u8>>
Returns the latest value for key
. Returns None
if there's no such value.
Implementors
impl StoresClientSessions for ClientSessionMemoryCache