#[repr(u8)]pub enum State {
PowerOff = 0,
SelfTest = 1,
Operational = 2,
Error = 3,
IntegrityUnverified = 4,
}Expand description
Module lifecycle state per FIPS 140-3 Section 7.2.
Variants§
PowerOff = 0
Module has not yet been initialized. No services are available.
SelfTest = 1
Power-up self-tests are currently executing. No services are available. This state is transient.
Operational = 2
All power-up self-tests have passed. Approved services are available.
Error = 3
A self-test has failed (either a power-up KAT or a conditional test). This state is terminal within a process: no further services are offered and all cached secret material must be treated as zeroized. The only recovery is to restart the containing process.
IntegrityUnverified = 4
The module reached the end of its pre-operational sequence without the software integrity test having been performed, so it was never verified against its integrity signature. Terminal, and no services are offered.
Distinct from State::Error because the two are different
faults with different owners. Error means a test ran and the
module failed it: the artifact is wrong. This state means nothing
checked the artifact at all — a front end initialised the module
without the integrity test in its inventory. Nothing here says
the module is corrupt; it says the module is unverified, and an
operator told only “Error” would go looking for corruption that
may not exist.