pub enum Level {
Classic,
QuantumSafe,
}Expand description
How the key ring is wrapped: chosen per repository, in the members file.
A new repository is quantum-safe (Level::NEW, owner 2026-10-30,
CRYPT-PQ-DEFAULT), and so is a new person’s key. A members file WITHOUT a
level line is classic (Level::UNSTATED): an existing repository keeps
its level, and nothing is migrated. Level::default() is Level::NEW.
Variants§
Classic
Wrapped to members’ X25519 (age1…) encryption keys: a ring harvested
today opens once a quantum computer breaks X25519. The visible opt-out
(gunnar crypt init --level classic) for members whose one key is classic.
QuantumSafe
Wrapped ONLY to age’s hybrid ML-KEM-768 + X25519 recipients
(age1pq1…): no stanza a quantum computer could open. The default.
Implementations§
Source§impl Level
impl Level
Sourcepub const NEW: Level = Level::QuantumSafe
pub const NEW: Level = Level::QuantumSafe
The level of a new repository and of a new person’s key, unless
asked otherwise: quantum-safe (owner 2026-10-30, CRYPT-PQ-DEFAULT). The
CLI (gunnar crypt init, gunnar crypt key new) and the console read it
here, so the default lives in one place.
Sourcepub const UNSTATED: Level = Level::Classic
pub const UNSTATED: Level = Level::Classic
The level of a members file without a level line: classic, as every
file was before the line existed. An existing repository keeps its level.
Sourcepub fn stanza_types(self) -> &'static [&'static str]
pub fn stanza_types(self) -> &'static [&'static str]
The age stanza types a key file of this level may carry (besides the
one random …-grease stanza age adds to every file).