Skip to content

Instantly share code, notes, and snippets.

@gglin001
Created November 2, 2021 06:38
Show Gist options
  • Save gglin001/9dcac0330cb35f0fe90003203563cafe to your computer and use it in GitHub Desktop.
Save gglin001/9dcac0330cb35f0fe90003203563cafe to your computer and use it in GitHub Desktop.
WireGuard over TCP with udptunnel

WireGuard over TCP with udptunnel

udptunnel is a small program which can tunnel UDP packets bi-directionally over a TCP connection. Its primary purpose (and original motivation) is to allow multi-media conferences to traverse a firewall which allows only outgoing TCP connections.

Server

# udptunnel -s 443 127.0.0.1/51820

Client

# udptunnel -c [SERVER PUBLIC IP]/443 127.0.0.1 50001
  • Remember to open TCP port 443 on the server's firewall
  • In the WireGuard client config file, replace the server's public IP (endpoint) with 127.0.0.1:50001
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment