aegis-delegate · proof
Declared module signatures, types, configuration, and source documentation.
Source: aegis/aegis-delegate/src/proof.rs. SHA-256: 2c5d8b0abe8f720355b2244a5b8da6b1ceaa9de670921a3d7cfedec71503dfd5.
This source reference follows declared modules and preserves feature attributes. It includes public declarations and implementation methods in those modules. Private-module exports and trait resolution still require the compiler; not every declaration is a crate-root import. Function bodies and constant values are omitted. Source comments describe their implementation context and are not a production deployment claim.
proof::create_delegation_proof
Creates a delegation proof by signing the delegation with the delegator's key.
Steps per spec §9.7:
- Construct delegation object (excluding proof field)
- Canonicalize via JCS (RFC 8785)
- Sign canonical bytes with delegator's delegation key (Ed25519)
Returns a fully formed [Delegation] with an attached cryptographic proof.
pub fn create_delegation_proof(
delegator_did: &str,
delegate_did: &str,
scope: DelegationScope,
expires: Option<DateTime<Utc>>,
signing_key: &SigningKey,
verification_method: &str,
) -> Result<Delegation, DelegationError>;Source line: 43.
proof::verify_delegation_proof
Verifies a delegation proof against the delegator's public key.
Reconstructs the canonical form of the delegation (without the proof), then verifies the Ed25519 signature contained in the proof's JWS field.
pub fn verify_delegation_proof(
delegation: &Delegation,
delegator_public_key: &VerifyingKey,
) -> Result<bool, DelegationError>;Source line: 95.