A high-performance SOCKS4a/SOCKS5 relay that assigns a unique IPv6 address to each connection from a given prefix.
Useful for load distribution, IP rotation, and bypassing rate limits.
- 🔁 Per-connection IPv6 address rotation
- 🌐 Works with any routed IPv6 prefix (e.g.
/64) - ⚡ Lightweight and fast (pure Go)
- 🐳 Docker support
- 🔧 Minimal configuration
go build -o bin/socks-ipv6-relay ./cmd/socks-ipv6-relayTest binary:
go build -o bin/socks-ipv6-relay-test ./cmd/socks-ipv6-relay-testbin/socks-ipv6-relay \
--prefix 2a01:4f9:abcd:1234::/64 \
--iface eth0 \
--listen :1080docker build -t socks-ipv6-relay .docker run --rm \
--network host \
--cap-add NET_ADMIN \
--cap-add NET_RAW \
socks-ipv6-relay \
--prefix 2a01:4f9:abcd:1234::/64 \
--iface eth0 \
--listen :1080| Flag | Description |
|---|---|
--prefix |
IPv6 prefix (e.g. /64) |
--iface |
Network interface (e.g. eth0) |
--listen |
SOCKS4a/SOCKS5 listen address |
--log-level |
Log level (debug, info, warn, error) |
- Linux host with IPv6 enabled
- Routed IPv6 prefix
- Kernel setting:
sudo sysctl -w net.ipv6.ip_nonlocal_bind=1The relay requires:
CAP_NET_ADMINCAP_NET_RAW- or root privileges
build:
go build -o bin/socks-ipv6-relay ./cmd/socks-ipv6-relay
build-test:
go build -o bin/socks-ipv6-relay-test ./cmd/socks-ipv6-relay-test
run-proxy *args:
bin/socks-ipv6-relay {{ args }}
test-proxy *args:
bin/socks-ipv6-relay-test {{ args }}
docker-build:
docker build -t socks-ipv6-relay .
docker-run *args:
docker run --rm \
--network host \
--cap-add NET_ADMIN \
--cap-add NET_RAW \
socks-ipv6-relay {{ args }}
docker-run-test *args:
docker run --rm \
--add-host=host.docker.internal:host-gateway \
--entrypoint /app/bin/socks-ipv6-relay-test \
socks-ipv6-relay {{ args }}Each outbound connection:
- Selects a random IPv6 address from the provided prefix
- Binds the socket to that address
- Forwards traffic via SOCKS4a/SOCKS5
This makes every connection appear to originate from a different IP.
Each request uses a different IPv6 source address.
MIT
