sd-radv: if lifetime < SD_RADV_DEFAULT_MAX_TIMEOUT_USEC, adjust timeout (#13491)
authorGeorg Müller <georgmueller@gmx.net>
Fri, 20 Sep 2019 08:23:45 +0000 (10:23 +0200)
committerMichael Biebl <biebl@debian.org>
Sun, 10 Nov 2019 23:58:41 +0000 (23:58 +0000)
commitc24e26bfa87fdd1dc407be0124ede954afbbd1e7
treee626ed3de7c3b23205280ee181e9ea244f8a9502
parent01fd6ffba9aedb4f9df1d7958219c5d554f6cc9a
sd-radv: if lifetime < SD_RADV_DEFAULT_MAX_TIMEOUT_USEC, adjust timeout (#13491)

The RFC states that lifetime (AdvDefaultLifetime) must be at least
MaxRtrAdvInterval (which more or less corresponds to SD_RADV_DEFAULT_MAX_TIMEOUT_USEC
in systemd).

To fulfill this limit, virtually lower MaxRtrAdvInterval and MinRtrAdvInterval
accordingly.

Also check that min is not lower than 3s and max is not lower than 4s.

(cherry picked from commit ef90b6a4fb9509f61b9b917bbe4db7343afe1853)
(cherry picked from commit d4cd0e9d3242f85141d835dd5a78d880b47a0817)

Gbp-Pq: Name sd-radv-if-lifetime-SD_RADV_DEFAULT_MAX_TIMEOUT_USEC-adju.patch
src/libsystemd-network/sd-radv.c