Wireguard cannot be on port 53

If i try to use port 53 as port on my older VyOS router with multiple versions of rolling release including one from today, with Wireguard i get a panic error.

If i do it on a new VM with no config prio i dont get this problem at all and it allows me to put wireguard on any port.

So im asking for help here as im stuck with this problem.

config used:

set interfaces wireguard wg1 address '10.0.190.1/32'
set interfaces wireguard wg1 address 'fd42:42:42::1/128'
set interfaces wireguard wg1 description 'mobile-access'
set interfaces wireguard wg1 peer mobile allowed-ips '10.0.190.0/24'
set interfaces wireguard wg1 peer mobile pubkey '6NJepbdEduV97+examplepublickeydontusethis='
set interfaces wireguard wg1 port '53'    

Error from VyOS on the older router running latest rolling release:

maltahl@colo3# set interfaces wireguard wg1 port 53
[edit]
maltahl@colo3# comp
[edit interfaces wireguard wg1]
>port 53
[edit]
maltahl@colo3# commit
[ interfaces wireguard wg1 ]
VyOS had an issue completing a command.

We are sorry that you encountered a problem while using VyOS.
There are a few things you can do to help us (and yourself):
- Make sure you are running the latest version of the code available at
  https://downloads.vyos.io/rolling/current/amd64/vyos-rolling-latest.iso
- Consult the forum to see how to handle this issue
  https://forum.vyos.io
- Join our community on slack where our users exchange help and advice
  https://vyos.slack.com

When reporting problems, please include as much information as possible:
- do not obfuscate any data (feel free to contact us privately if your
  business policy requires it)
- and include all the information presented below

Report Time:      2020-10-01 10:13:29
Image Version:    VyOS 1.3-rolling-202009300117
Release Train:    equuleus

Built by:         autobuild@vyos.net
Built on:         Wed 30 Sep 2020 01:17 UTC
Build UUID:       5389d291-d2be-4c52-8f78-43cc7201c749
Build Commit ID:  a058b040f1d406

Architecture:     x86_64
Boot via:         installed image
System type:      KVM guest

Hardware vendor:  QEMU
Hardware model:   Standard PC (i440FX + PIIX, 1996)
Hardware S/N:
Hardware UUID:    640cf4a7-15d7-4067-9e88-6a8a59b57849

Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/interfaces-wireguard.py", line 117, in <module>
apply(c)
  File "/usr/libexec/vyos/conf_mode/interfaces-wireguard.py", line 109, in apply
w.update(wireguard)
  File "/usr/lib/python3/dist-packages/vyos/ifconfig/wireguard.py", line 229, in update
self._cmd(cmd.format(**peer))
  File "/usr/lib/python3/dist-packages/vyos/ifconfig/control.py", line 51, in _cmd
return cmd(command, self.debug)
  File "/usr/lib/python3/dist-packages/vyos/util.py", line 179, in cmd
raise OSError(code, feedback)
PermissionError: [Errno 1] failed to run command: wg set wg1 private-key /config/auth/wireguard/default/private.key listen-port 53 fwmark 0 peer 6NJepbdEduV97+examplepublickeydontusethis= preshared-key /dev/null allowed-ips 10.0.190.0/24
returned:
exit code: 1

noteworthy:
cmd 'wg set wg1 private-key /config/auth/wireguard/default/private.key listen-port 53 fwmark 0 peer 6NJepbdEduV97+examplepublickeydontusethis= preshared-key /dev/null allowed-ips 10.0.190.0/24'
returned (out):

returned (err):
Unable to modify interface: Address already in use

[[interfaces wireguard wg1]] failed
Commit failed

Hi Maltahl!

While looking at your error i see: Unable to modify interface: Address already in use, this means that port 53 is already in use on your device.

as port 53 is DNS, do you have a DNS server configured on your device?

Was DNS forwarding. My bad.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.