pub struct IdentityBundle {
pub identity_did: IdentityDID,
pub public_key_hex: PublicKeyHex,
pub curve: CurveType,
pub attestation_chain: Vec<Attestation>,
pub kel: Vec<Event>,
pub kel_attachments: Vec<String>,
pub device_kels: Vec<BundleDeviceKel>,
pub bundle_timestamp: DateTime<Utc>,
pub max_valid_for_secs: u64,
}Expand description
An identity bundle for stateless verification in CI/CD environments.
Contains all the information needed to verify commit signatures without requiring access to the identity repository or daemon.
Fields§
§identity_did: IdentityDIDThe DID of the identity (e.g., "did:keri:...")
public_key_hex: PublicKeyHexThe public key in hex format for signature verification.
curve: CurveTypeCurve of public_key_hex. Carried in-band so verifiers never infer
curve from byte length. Defaults to P-256 when absent (older bundles
shipped before this field existed).
attestation_chain: Vec<Attestation>Chain of attestations linking the signing key to the identity
kel: Vec<Event>The identity’s KEL events, oldest first (parsed at the deserialize boundary, not held as loose JSON). Carried so KEL-native commit verification stays stateless on CI runners with no identity store. Empty in bundles exported before this field existed. Wire form is unchanged — a JSON array of event objects.
kel_attachments: Vec<String>The CESR signature attachment (hex) for each kel event, in the same
order. Lets a stateless verifier AUTHENTICATE the bundle’s KEL — verify
each event is signed by the controlling key-state — not just replay it
structurally (RT-002). A bundle whose kel_attachments length differs
from kel, or whose signatures don’t verify, fails closed. Empty in
pre-RT-002 bundles.
device_kels: Vec<BundleDeviceKel>Delegated device KELs anchored under this identity’s root. Commits are signed by a DEVICE AID, so a stateless verifier needs the device’s KEL, not only the root’s. Each entry authenticates exactly like the root KEL (per-event hex CESR attachments), with the root’s seal index resolving the delegation. Empty in bundles exported before this field existed — and for identities whose signing DID IS the root.
bundle_timestamp: DateTime<Utc>UTC timestamp when this bundle was created
max_valid_for_secs: u64Maximum age in seconds before this bundle is considered stale
Implementations§
Source§impl IdentityBundle
impl IdentityBundle
Sourcepub fn check_freshness(
&self,
now: DateTime<Utc>,
) -> Result<(), AttestationError>
pub fn check_freshness( &self, now: DateTime<Utc>, ) -> Result<(), AttestationError>
Check that this bundle is still within its TTL.
Args:
now: The current time, injected for deterministic verification.
Usage:
bundle.check_freshness(Utc::now())?;Trait Implementations§
Source§impl Clone for IdentityBundle
impl Clone for IdentityBundle
Source§fn clone(&self) -> IdentityBundle
fn clone(&self) -> IdentityBundle
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more