Skip to contentSkip to conversation

event for peer connection

DISCUSSION [email protected] 2 participants 2 messages Mar 7, 2021

lore
Share & tools
lore
#0 lore raw

Hello,

first thank you all for your great work on Wireguard!

We would like to switch to wireguard at work but for our setup we need some automatic configuration based on the clients and their IP numbers. Is there a way to get notified when peers connect or send handshake packets? We'd like to avoid polling as the configuration needs to be done rather quickly on a connect for a pleasant user experience. A file in /sys or /proc that can be waited on would be best but listening for netlink events would be useful, too.

Servus, Frank

#1 lore raw

Hi Frank,
I have created a patch for the linux kernel[1], that notifies you about changes of the endpoint address over netlink. If you could test it and give some feedback if it works for you that would be great.

[1] https://lore.kernel.org/patchwork/patch/1366219/

Best Regards,
Linus

Am 24.02.21 um 01:11 schrieb [email protected]:

Quoted 9 lines

Hello,

first thank you all for your great work on Wireguard!

We would like to switch to wireguard at work but for our setup we need some automatic configuration based on the clients and their IP numbers. Is there a way to get notified when peers connect or send handshake packets? We'd like to avoid polling as the configuration needs to be done rather quickly on a connect for a pleasant user experience. A file in /sys or /proc that can be waited on would be best but listening for netlink events would be useful, too.

Servus, Frank