Wireguard blocks ssh/smb :(

https://lemmy.world/post/4353701

Wireguard blocks ssh/smb :( - Lemmy.world

Hello. I have wireguard set but the second it runs, services like ssh (22) and smb (455/445?) stop working. nmap thinks my system is down. Here is my config, I followed debian’s guide since my server is Deb12: [Interface] Address = 192.168.1.120/24 SaveConfig = true PostUp = iptables -A FORWARD -i %i -j ACCEPT; iptables -t nat -A POSTROUTING -o wlp1s0 -j MASQUERADE PostDown = iptables -D FORWARD -i %i -j ACCEPT; iptables -t nat -D POSTROUTING -o wlp1s0 -j MASQUERADE ListenPort = 51820 PrivateKey = qEKy9m0n4zqBh/Cw1xzBPA13/+Qc/LewRwVwUFRI4H0= [Peer] PublicKey = wjBActPSU0QyUGMQBeATuzPyuPTiQE+ojb0JVhD6tnA= AllowedIPs = 192.168.1.230/32 Endpoint = 192.168.1.230:50104 No extra config was made.

Could be your routing rules? Here’s what I use and it routes to anything inside my home network:

PostUp = iptables -A FORWARD -i %i -j ACCEPT; iptables -A FORWARD -o %i -j ACCEPT; iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE PostDown = iptables -D FORWARD -i %i -j ACCEPT; iptables -D FORWARD -o %i -j ACCEPT; iptables -t nat -D POSTROUTING -o eth0 -j MASQUERADE

Just be sure to replace eth0 with the name of your adapter before you try it.

Unfortunely that didn’t work.

The WG server is also servicing SSH and SMB.

are your services accessible through the wg interface on the server ? Try with nmap -Pn -A -T4 -p CHANGEME_TO_SSH_OR_SMB IPADDR_OF_WG_NIC