[](https://opensource.org/licenses/BSD-2-Clause)
[](https://opensource.org/licenses/MIT)
[](https://ci.appveyor.com/project/KizzyCode/WireguardRelay-rust)
[](https://docs.rs/wgproxy)
[](https://crates.io/crates/wgproxy)
[](https://crates.io/crates/wgproxy)
[](https://deps.rs/crate/wgproxy)
# `wgproxy`
Welcome to `wgproxy` 🎉
`wgproxy` is a tiny layer-4-proxy to bridge WireGuard®-like traffic via a jump-host. This is e.g. useful to bridge from
IPv4-only networks to IPv6-only servers, or to route the traffic via specific gateways.
It basically works as a stateful NAT: A _valid_ WireGuard handshake message is used to allocate a NAT-mapping, which in
turn is used to forward/bridge packets between the client and the server.
## Example
```sh
# Export the necessary environment variables
export WGPROXY_SERVER="my-wireguard-server.invalid:51820"
export WGPROXY_PUBKEY="<the base64 server public key>"
# Configure optional environment variables
export WGPROXY_LISTEN="[::]:51820"
export WGPROXY_TIMEOUT="60"
export WGPROXY_LOGLEVEL="2"
# Start the proxy
wgproxy
```
## Microsoft Windows Support
Microsoft Windows is **not** an officially supported target, and is not tested. While the application should compile and
might work as expected, Windows networking has subtle differences and might cause weird errors.