Bug in wireguard configurations parsing

Started by meyergru, January 29, 2025, 02:49:42 PM

Previous topic - Next topic
I saw this error in my wireguard log after upgrading to 25.1:

2024-11-02T12:41:43 Error wireguard /usr/local/opnsense/scripts/Wireguard/wg-service-control.php: The command '/usr/bin/wg syncconf 'wg0' '/usr/local/etc/wireguard/wg0.conf'' returned exit code '1', the output was 'Name does not resolve: `xxx.yyy.de:6010' Configuration parsing error'

The corresponding line in the "Peer" section of /usr/local/etc/wireguard/wg0.conf is:

Endpoint = xxx.yyy.de:6010

This configuration has not been hand-edited, it was created via the web UI.
Intel N100, 4 x I226-V, 16 GByte, 256 GByte NVME, ZTE F6005

1100 down / 440 up, Bufferbloat A+

It means the DNS lookup failed at the time syncconf was executed.  It's not really a syntax error, just a fatal error trying to convert DNS to IP because most of those DNS-in-the-system things are only ever resolved once and then static IP addresses for the rest of their lifetime.


Cheers,
Franco

Ah, correct. It only looks as if it was the port...
Intel N100, 4 x I226-V, 16 GByte, 256 GByte NVME, ZTE F6005

1100 down / 440 up, Bufferbloat A+