[RFC PATCH 00/14] odhcpd config value clamping

Paul D newtwen at gmail.com
Sun Jun 30 13:32:42 PDT 2024


Any comments?



On 2024-05-10 00:30, Paul Donald wrote:
> Clamp values read from config to RFC mandated sane values instead of just
> complaining. We also now implement valid_lifetime for ULA prefixes.
> This is useful if you need to sunset or remove one from circulation.
> ( Interestingly, if you spin up dev devices frequently which spam the
> network with new ULA each time, which have no expiry, interesting things
> start to happen. )
> Fixed also a bug in MTU handling.
> 
> Paul Donald (14):
>   config: refactor parse_leasetime() - branch amount remains same
>   router: Apply updated values from RFC8319 (updates RFC4861) to RA/ND
>   config: clamp ra_mininterval, ra_maxinterval, ra_lifetime at load time
>   router: refactor calc_ra_lifetime, and define ra_lifetime as uint32_t
>   router: redefine ra_mininterval and ra_maxinterval as uint32_t
>   config: implement RFC4861 AdvValidLifetime (make configurable)
>   config: lease times are all UINT32_MAX; drop double size handling
>   router: clamp prefix valid_lt to interface valid_lifetime
>   config: clamp ra_reachabletime to RFC maximum (instead of complaining)
>   config: clamp ra_hoplimit to maximum (instead of complaining)
>   config: clamp ra_retranstime
>   config: clamp ra_mtu into 1280-65535 range
>   config: clamp dhcpv6_hostid_len
>   config: clamp dhcpv6_pd_min_len
> 
>  README       |   2 +
>  src/config.c | 162 +++++++++++++++++++++++++++++++++------------------
>  src/odhcpd.h |   7 ++-
>  src/router.c |  34 +++++------
>  src/router.h |  25 +++++++-
>  5 files changed, 148 insertions(+), 82 deletions(-)
> 




More information about the openwrt-devel mailing list