Skip to main content

microvms_edges/session/
mod.rs

1// SPDX-License-Identifier: Apache-2.0
2//! The session's production pieces: the reqwest backend and the sockets.
3//!
4//! [`forward`] is the port forwarder's listener and its 403-vs-502 diagnostic. [`tunnel`] is
5//! the WebSocket client that carries raw TCP to the daemon's relay, and [`shell`] is the
6//! interactive shell over the same kind of socket. [`serve`] is the accept loop the CLI and
7//! the SDKs run both of the first two in. Each builds on the session's
8//! `ProxyAuth` in `microvms-app`, which mints the tokens they present.
9
10pub mod forward;
11pub mod http;
12pub mod serve;
13pub mod shell;
14pub mod tunnel;
15#[cfg(test)]
16mod tunnel_fuzz;
17
18pub use forward::{
19    DEFAULT_EXCHANGE_TIMEOUT, ForwardClient, ForwardEvent, ForwardSpec, forwards_request_header,
20    refusal_explanation, upstream_url,
21};
22pub use http::ReqwestBackend;
23pub use tunnel::{TUNNEL_CHUNK_BYTES, TunnelEnd, explain_close, relay_connection, tunnel_url};