salty-stun is a STUN server that runs inside a WireGuard® tunnel. It listens for incoming STUN requests and responds with the transport address of the WireGuard endpoint. This allows two peers to establish a P2P VPN tunnel through NATs.
salty-stun uses libsodium and libb2 for cryptographic operations. On a debian-based system, you can install these dependencies with:
$ sudo apt install libsodium-dev libb2-devTo build and install salty-stun, run the following commands:
$ meson setup build
$ meson compile -C build
$ sudo meson install -C buildSee the man page salty-stun(1) for usage information.
The idea is based on a blog post by Rytis Karpuška at NordVPN: Reaching Beyond 1Gbps: How we achieved NAT traversal with vanilla WireGuard.
WireGuard is a registered trademark of Jason A. Donenfeld. This project is not affiliated with or endorsed by WireGuard or its developers.