Without this change, it can take until the handshake timeout period to reestablish with the peer. After this change, the handshake occurs as soon as possible and the link is reestablished much more quickly.
Signed-off-by: Derrick Pallas <[email protected]> --- src/netlink.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/netlink.c b/src/netlink.c index 3458c81..f6b10ad 100644 --- a/src/netlink.c +++ b/src/netlink.c @@ -539,6 +539,8 @@ static int wg_set_device(struct sk_buff *skb, struct genl_info *info) peer_list) { if (!wg_noise_precompute_static_static(peer)) wg_peer_remove(peer); + else + wg_peer_reset_keys(peer); } wg_cookie_checker_precompute_device_keys(&wg->cookie_checker); up_write(&wg->static_identity.lock); -- 2.19.2 _______________________________________________ WireGuard mailing list [email protected] https://lists.zx2c4.com/mailman/listinfo/wireguard
