Expand description
Runtime-agnostic meerkly exit-node core.
This crate is the single implementation of the exit node, wrapped by every
platform binding (client-napi for Node, client-ffi for
Kotlin/Go/Swift/Python). It holds exactly one QUIC connection to one gateway,
opens outbound TCP sockets on demand, and reconnects automatically.
Runtime ownership. Unlike a Node addon, the FFI bindings have no ambient
async runtime, so ProxyClient takes an explicit tokio::runtime::Handle
and runs the supervisor on it. The endpoint driver and every connection task
therefore share one runtime regardless of which runtime drives start().
Ephemeral-session lifecycle. Built for host apps that cannot run in the
background: fast start(), clean fast stop(), and no assumption that a
session lasts more than seconds.
Structs§
- Client
Config - Proxy
Client - A handle to a single exit-node client.
- Supervisor
Enums§
- CaCert
- Where the gateway CA comes from.
- State
- What the client is currently doing. Surfaced to host apps so they can show connection state without polling the gateway.
Constants§
- DEFAULT_
CONNECT_ TIMEOUT - How long to wait when dialling a target on the gateway’s behalf.
- DEFAULT_
GATEWAY_ ADDRESSES - The production gateway, used when a host does not name one itself.
- DEFAULT_
KEEP_ ALIVE - QUIC keepalive interval — a fallback, not a second heartbeat.
- DEFAULT_
MAX_ BACKOFF - DEFAULT_
MAX_ IDLE - How long silence is tolerated before the connection is considered dead.
- DEFAULT_
MIN_ BACKOFF - Reconnect backoff bounds.
- DEFAULT_
START_ TIMEOUT - How long
startwaits for the first connection. - VERSION
- Semantic version of the client core, surfaced to bindings for the register
handshake’s
client_version.
Functions§
- default_
ca_ cert_ path - Default CA path, overridable by environment so a deployment does not have to thread the path through application code.
Type Aliases§
- Rejection
Slot - The reason the gateway gave the last time it refused this client, shared
between the supervisor that hears it and the
crate::ProxyClientthat reports it. Cleared once a gateway accepts the client again.