Summary
The new boot-lifetime RNG fault mirror is not set on the active-error recovery path. If SECS/CECS remains asserted for 100 polls, random32() calls reset_rng(), which clears SEIS/CEIS and recursively resumes without ever setting rng_seed_error_seen. A later health gate can therefore see neither the hardware interrupt latch nor the software mirror.
Found while auditing PR #604 at exact head 1d446ccbc9cf32a6e499990e65bcf7b358f1325b.
Evidence
lib/rand/rng.c:51-65 documents rng_seed_error_seen as boot-lifetime and one-way.
lib/rand/rng.c:102-107 sets it only after an interrupt is observed with current SECS/CECS clear.
lib/rand/rng.c:108-115 handles a still-active fault by waiting 100 polls and calling reset_rng() without setting the mirror.
lib/rand/rng.c:67-86 clears SEIS/CEIS and recursively draws again.
lib/rand/rng_health.c:72-81 trusts either the current hardware bits or this software mirror to detect the historical fault.
Impact
High — entropy boundary can fail open after a hardware continuous-test error. Key-generation ceremonies may accept output from a source that the code explicitly says must remain distrusted until power cycle.
Acceptance criteria
Summary
The new boot-lifetime RNG fault mirror is not set on the active-error recovery path. If
SECS/CECSremains asserted for 100 polls,random32()callsreset_rng(), which clearsSEIS/CEISand recursively resumes without ever settingrng_seed_error_seen. A later health gate can therefore see neither the hardware interrupt latch nor the software mirror.Found while auditing PR #604 at exact head
1d446ccbc9cf32a6e499990e65bcf7b358f1325b.Evidence
lib/rand/rng.c:51-65documentsrng_seed_error_seenas boot-lifetime and one-way.lib/rand/rng.c:102-107sets it only after an interrupt is observed with currentSECS/CECSclear.lib/rand/rng.c:108-115handles a still-active fault by waiting 100 polls and callingreset_rng()without setting the mirror.lib/rand/rng.c:67-86clearsSEIS/CEISand recursively draws again.lib/rand/rng_health.c:72-81trusts either the current hardware bits or this software mirror to detect the historical fault.Impact
High — entropy boundary can fail open after a hardware continuous-test error. Key-generation ceremonies may accept output from a source that the code explicitly says must remain distrusted until power cycle.
Acceptance criteria
SECS/CECSpath.random_buffer_checked()to fail and wipe its destination.