Wireguard is not working - 24.1.7

Started by abbinett, May 24, 2024, 09:47:18 PM

Previous topic - Next topic
May 24, 2024, 09:47:18 PM Last Edit: May 25, 2024, 06:40:21 PM by abbinett
Wireguard stopped working since version 24.1.6. I verified the keys both on mobile, and laptops (see the wg config below).  The error I'm getting is  "[NET] peer(WVSy...H7jQ) - Handshake did not complete after 5 seconds, retrying (try 2)". The internet suggested to recreate the instance and its peers, and rebooted but that didn't help.

Opnsense version: OPNsense 24.1.7_4-amd64 installed on baremetal


route table:
root@router:~ # netstat -nr -f inet
Routing tables

Internet:
Destination        Gateway            Flags     Netif Expire
10.10.10.0/24      link#16            U           wg0
10.10.10.1         link#16            UHS         lo0
10.10.10.2         link#16            UHS         wg0
10.10.10.3         link#16            UHS         wg0
10.10.10.4         link#16            UHS         wg0

See my firewall rules for the WG and WAN interface:

WAN:
IPv4 UDP    *    *    WAN address    51821    *    *

WG
IPv4 TCP/UDP    HomeWireGuard net    *    HomeWireGuard address    53 (DNS)    *    *   
IPv4 *    HomeWireGuard net    *    *    *    *    *

What did I do wrong?

The verified the keys much in the instance and its peers:

root@router:~ # wg showconf wg0
[Interface]
ListenPort = 51821
PrivateKey = ....

[Peer]
PublicKey = ....
AllowedIPs = 10.10.10.4/32

[Peer]
PublicKey = ....
AllowedIPs = 10.10.10.3/32

[Peer]
PublicKey = .....
AllowedIPs = 10.10.10.2/32