pub struct IdentityGenesis {
pub handle: [u8; 32],
pub roots: Vec<RootKey>,
pub signatures: Vec<RootSignature>,
}Expand description
How an identity begins (P7-08): its handle, its first roots, and each
root’s signature over both, so every root proves it is held. For a
security key identity the handle is random and is also the key’s
resident credential’s user.id, so a key put into a device that has
never seen it says which identity it roots.
The genesis fixes the identity’s id (Self::user): later root
changes, made in its states, never change it.
Fields§
§handle: [u8; 32]§roots: Vec<RootKey>§signatures: Vec<RootSignature>One for each root, in roots’ order, over Self::message.
Implementations§
Source§impl IdentityGenesis
impl IdentityGenesis
Sourcepub fn message(handle: &[u8; 32], roots: &[RootKey]) -> Option<Vec<u8>>
pub fn message(handle: &[u8; 32], roots: &[RootKey]) -> Option<Vec<u8>>
What each root signs: GENESIS_DOMAIN, the handle (32 bytes),
the count of roots (u8), then each root (RootKey::bytes) in
order. None for more roots than a byte counts.
Sourcepub fn verify(&self) -> Result<(), GenesisError>
pub fn verify(&self) -> Result<(), GenesisError>
Whether it is a genesis: 1 to MAX_ROOTS valid roots, none
twice, each with its signature over Self::message.
Sourcepub fn user(&self) -> PortableUserId
pub fn user(&self) -> PortableUserId
The identity’s id. A genesis of one phrase root keeps P7-01’s id,
that root’s public key (the user’s decision, 2026-10-11: no phrase
identity moves); any other’s is
blake3::derive_key(USER_ID_CONTEXT, message). Signatures
are left out, since an ECDSA one differs each time it is made.