Struct secret_stream::OwningClient [] [src]

pub struct OwningClient<S>(_);

A future that initiates a secret-handshake and then yields a channel that encrypts/decrypts all data via box-stream.

This copies the handshake keys so that it is not constrained by the key's lifetime.

Methods

impl<S: AsyncRead + AsyncWrite> OwningClient<S>
[src]

[src]

Create a new OwningClient to connect to a server with known public key and app key over the given stream.

This copies the handshake keys so that it is not constrained by the key's lifetime.

Ephemeral keypairs can be generated via sodiumoxide::crypto::box_::gen_keypair.

Trait Implementations

impl<S: AsyncRead + AsyncWrite> Future for OwningClient<S>
[src]

A successful value

An error

[src]

Attempt to resolve the future to a final value, registering the current task for wakeup if the value is not yet available. Read more

Auto Trait Implementations

impl<S> !Send for OwningClient<S>

impl<S> !Sync for OwningClient<S>