Module client

Module client 

Source
Expand description

SNAP tunnel client.

Structs§

AutoSessionRenewal
Automatic session renewal configuration.
ClientBuilder
SNAP tunnel client builder.
Control
Control can be used to send control messages to the server
Receiver
SNAP tunnel receiver.
Sender
SNAP tunnel sender.

Enums§

AddrAssignError
Address assignment error.
ControlError
SNAP tunnel control errors.
ParseResponseError
Parse response error.
RenewTaskError
Token renew task error.
SendControlRequestError
Send control request error.
SnapTunError
SNAP tunnel errors.

Constants§

CTRL_RESPONSE_BUF_SIZE
All control requests issued by the client MUST NOT exceed CTRL_REQUEST_BUF_SIZE bytes.
DEFAULT_RENEWAL_WAIT_THRESHOLD
Lead time for session renewal. Renewal is triggered when the current time is later than the token expiry minus the lead time.

Functions§

renew_session
Renew SNAP tunnel session.

Type Aliases§

TokenRenewError
Token renewal error.
TokenRenewFn
Function type for renewing tokens.