[][src]Trait susyp2p_noise::Protocol

pub trait Protocol<C> {
    fn params_ik() -> ProtocolParams;
fn params_ix() -> ProtocolParams;
fn params_xx() -> ProtocolParams;
fn public_from_bytes(s: &[u8]) -> Result<PublicKey<C>, NoiseError>; }

A Noise protocol over DH keys of type C. The choice of C determines the protocol parameters for each handshake pattern.

Required methods

fn params_ik() -> ProtocolParams

The protocol parameters for the IK handshake pattern.

fn params_ix() -> ProtocolParams

The protocol parameters for the IX handshake pattern.

fn params_xx() -> ProtocolParams

The protocol parameters for the XX handshake pattern.

fn public_from_bytes(s: &[u8]) -> Result<PublicKey<C>, NoiseError>

Construct a DH public key from a byte slice.

Loading content...

Implementors

Loading content...