wg-socks 0.1.1

socks5 server (lib) from wireguard config
docs.rs failed to build wg-socks-0.1.1
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.

wg-socks

crates.io docs.rs

Turn a WireGuard config into a local SOCKS5 proxy.

Load a wireguard style config, start the proxy, and route traffic through bind address (127.0.0.1:1080).

Quick start

#[tokio::main]
async fn main() -> anyhow::Result<()> {
    let proxy = wg_socks::WgSocksProxy::start_from_file(
        "wireguard.conf",
        "127.0.0.1:1080".parse()?)
        .await?;

    // use proxy.proxy_url()

    proxy.shutdown();
    Ok(())
}

API entry points: start, start_from_str, start_from_file