INNER CODE UNIT · Rust
new
eepnet/emissary · emissary-cli/src/proxy/http/mod.rs:89
pub async fn new(
config: HttpProxyConfig,
samv3_tcp_port: u16,
http_proxy_ready_tx: Option<oneshot::Sender<()>>,
address_book_handle: Option<Arc<dyn AddressBook>>,
) -> crate::Result<Self> {
tracing::info!(
target: LOG_TARGET,
host = %config.host,
port = %config.port,
outproxy = ?config.outproxy,
"starting http proxy",
);
// create session before starting the tcp listener for the proxy
let tunnel_config = config.tunnel_config.unwrap_or_default();
let session = Session::<style::Stream>::new(SessionOptions {
publish: false,