DefGuard / defguard

The only _real_ 2FA MFA WireGuard Enterprise VPN with build-in SSO, hardware keys management and more!
https://defguard.net
Other
1.11k stars 35 forks source link

Generated config file is invalid when the AllowedIPs field is left blank #636

Closed t-aleksander closed 3 months ago

t-aleksander commented 4 months ago

If the location doesn't have any allowedips set (which is optional), its generated config file (downloadable during the enrollment or from the dashboard) will be impossible to parse by the wg-quick command or the wireguard GUI client.

[#] ip link add lokacja type wireguard
[#] wg setconf lokacja /dev/fd/63
Line unrecognized: `AllowedIPs='
Configuration parsing error
[#] ip link delete dev lokacja

Currently the AllowedIPs line looks like this in such scenario:

AllowedIPs =

Instead, if there are no allowedips specified, it should be empty altogether. The issue doesn't occur when importing the config via the defguard client menu.