Skip to main content

Module asynch

Module asynch 

Source
Expand description

Async dial and accept over tokio-rustls, for any AsyncRead + AsyncWrite stream.

Structs§

PairDial
The asynchronous PairDial.

Functions§

accept
Accepts a peer over io, completing the handshake before returning.
accept_with
Accepts a peer over io, choosing the configuration from the ClientHello (for example by its offered ALPN protocols), so one port can serve peers and other clients.
announce
crate::announce over an async stream.
announce_as
crate::announce_as over an async stream.
dial
Dials a peer over io, completing the handshake before returning. The server name sent is SERVER_NAME; dial_named sends another.
dial_named
dial sending name as the server name, as crate::dial_named does.
pair_accept
crate::pair_accept over an async stream; it waits for the operator without blocking the runtime, and sweeps desk every second meanwhile so expiry is seen.
pair_dial
crate::pair_dial over an async stream.
pair_respond
Runs the responder’s side of pairing on a connection already accepted with pair_server_config (for example chosen by accept_with for a client that offered the pairing ALPN), as identity, for a client from source. The exchange waits at most PairConfig::timeout from this call.
receive_announcement
crate::receive_announcement over an async stream.