Allow ifconfig to show informations about wireguard bridges
Details
ifconfig wg0 wg0: flags=10080c1<UP,RUNNING,NOARP,MULTICAST,LOWER_UP> metric 0 mtu 1420 options=80000<LINKSTATE> inet 10.10.0.3 netmask 0xffffff00 groups: wg wg public key WwnsbWpa3aNtU932O4mVPaL+TLJeZMYKiVKyDFTuwzQ= wg listen-port 51820 wg peer 41eBMV3uKaE+KS2Q7Yibq+Z+BgSjwW7JLF76JvXQpj0= endpoint: 176.31.115.77:51820 allowed ips: 10.10.0.0/24 last handshake: 92 seconds keepalive: 25 seconds wg peer zL/qcilesyKX6+KslWhTtRVLD2dWJXUQTezk7lEHIS8= allowed ips: 192.168.1.0/24, 10.10.0.6/32 wg peer YNZ1B/R1EUnupTbv3G+c8EyQeF62D16D9O+4dc9REy4= endpoint: 192.168.1.48:51820 allowed ips: 10.10.0.2/32 last handshake: 3956 seconds nd6 options=109<PERFORMNUD,IFDISABLED,NO_DAD>
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Skipped - Unit
Tests Skipped - Build Status
Buildable 54757 Build 51646: arc lint + arc unit
Event Timeline
I'm not sure about how useful this is to me. I use ifconfig to take a glance at all interfaces and if I want to learn more specifically about the state of the wg interface, I just run wg. I know it's obvious, I just mean that I never missed this information when looking at ifconfig output. On the other hand, with this patch, the output is longer and somewhat less readable.
But that's just my opinion of a user, if it's a generally desirable feature then I won't protest.
I plan to also add the commands to set it up from ifconfig as well.
So the wg command is not necessary for basic setups like in openbsd
I do wonder if they would've made the same decision today; wg(8) wasn't dual-licensed back when they gained wireguard support, but now it is and we include it in base.