Sample Header Ad - 728x90

annot redirect host port 53 to allow VPN client connections to host port 53

0 votes
0 answers
67 views
I have pihole in rootless podman on port 1053 and wireguard, openvpn servers (not in podman) on the same host (Debian bookworm). Trying to redirect port 53 to 1053. It works for another hosts in lan, but doesn't work for wg and openvpn clients. Tried: 1) sudo iptables -w -t nat -A PREROUTING -d 192.168.1.100 -p udp --dport 53 -j REDIRECT --to-ports 1053 From another host in lan: dig @192.168.1.100 google.com # ok. From wg client (ip 10.10.0.2): dig @192.168.1.100 -p 1053 google.com # ok; dig @192.168.1.100 google.com # connection time out; nc -v -n -u 192.168.1.100 53 # nothing. 2) sudo socat UDP4-LISTEN:53,reuseaddr,fork,su=nobody UDP4:192.168.1.100:1053,reuseaddr From another host in lan - all ok. From wg client: dig # the same results as above. nc -v -n -u 192.168.1.100 53 # Connection succeeded.
Asked by Kamrad2011 (1 rep)
Nov 8, 2024, 01:07 PM
Last activity: Jun 17, 2025, 05:30 AM