Struct strobe_rs::Strobe [−][src]
pub struct Strobe { /* fields omitted */ }The main Strobe object. This is currently limited to using Keccak-f[1600] as the internal permutation function. For more information on this object, the protocol specification is a great resource.
Methods
impl Strobe[src]
impl Strobepub fn new(proto: Vec<u8>, sec: SecParam) -> Strobe[src]
pub fn new(proto: Vec<u8>, sec: SecParam) -> StrobeMakes a new Strobe object with a given protocol byte string and security parameter.
pub fn version_str(&self) -> String[src]
pub fn version_str(&self) -> StringReturns a string of the form Strobe-Keccak-<sec>/<b>v<ver> where sec is the bits of
security (128 or 256), b is the block size (in bits) of the Keccak permutation function,
and ver is the protocol version.
pub fn ad(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn ad(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn key(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn key(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn prf(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn prf(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn send_clr(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn send_clr(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn recv_clr(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn recv_clr(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn send_enc(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn send_enc(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn recv_enc(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn recv_enc(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn send_mac(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn send_mac(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn recv_mac(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn recv_mac(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>pub fn ratchet(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>[src]
pub fn ratchet(
&mut self,
data: Vec<u8>,
metadata: Option<(OpFlags, Vec<u8>)>,
more: bool
) -> Result<Vec<u8>, AuthError>