Compare commits

..
Author SHA1 Message Date
atlas
4e4e9f8a60 hive-tls: leafValidityDays default 30 (per mara: ahead of the ~47-day proposal)
Short-lived leaf bounds the blast radius of a key compromise. Doc notes
the renewal caveat: re-sign is activation-only today, so a hive that
stays up >30 days without a rebuild would need a periodic re-sign timer
to avoid leaf expiry (follow-up).
2026-06-23 10:46:11 +02:00
atlas
5ed0288634 hive-tls: default leafValidityDays to 397 (was 3650/~10y)
A 10-year leaf is pointless given the leaf auto-rotates (re-signed
within 30 days of expiry) and is long enough to make browsers warn.
397 days sits just under the 398-day CA/Browser-Forum leaf cap (so
browsers accept it) while bounding the blast radius of a leaf-key
compromise. The re-sign runs at service activation (hive-tls-ca is a
oneshot, no timer), so 397 stays comfortably above any gateway
rebuild gap.
2026-06-23 10:46:11 +02:00

View file

@ -63,14 +63,22 @@ in
leafValidityDays = lib.mkOption {
type = lib.types.int;
default = 3650;
default = 30;
description = ''
Validity window of the gateway leaf cert in days (default ~10y).
The leaf is re-signed by the (stable) CA when it is missing or
within 30 days of expiry; because it shares the CA anchor, a
rotation does not disturb consumer trust. Browsers may warn on
long-lived leaves, but agents and federation peers validate
against the CA, not browser CA/B-forum limits.
Validity window of the gateway leaf cert in days (default 30).
Short-lived by design ahead of the CA/Browser-Forum's move
toward ~47-day max lifetimes which bounds the blast radius of a
leaf-key compromise. The leaf is re-signed by the (stable) CA
when it is missing or near expiry; because it shares the CA
anchor, a rotation does not disturb consumer trust. Agents and
federation peers validate against the CA, not browser CA/B-forum
limits. NOTE: at this short a window the re-sign must run more
often than the leaf lifetime. Today `hive-tls-ca` re-signs at
service activation (boot/rebuild) only there is no periodic
re-sign timer yet so a hive that does not reboot within the
validity window would let the leaf expire. Keep that in mind (or
add a re-sign timer) when running a hive that stays up for long
stretches without a rebuild.
'';
};
};