Expand description
Delegation & credential-chain logic (§21, legal_logic.md) — the trust fabric.
Legal power and identity flow through chains of authorization. This module governs how
authority propagates along a delegation DAG and how revocation of an upstream node
cascades to defeat every downstream dependent (ZCAP-LD / capability chains; Open Badges
EndorsementCredential). Authority delegation edges are (delegator, q42:delegatesTo, delegatee). Bounded BFS, zero-heap.
Constants§
- MAX_
DELEGATION_ NODES - Bound on distinct nodes in one delegation query.
Functions§
- attenuates
- Attenuation (ZCAP-LD / Macaroons): a sub-delegation’s capability set
childis valid only if a SUBSET of the delegator’sparentset — a delegatee never gains MORE authority than the delegator holds. (Empty child trivially attenuates.) - authority_
after_ crl - Does
agentstill hold authority fromroot_authorityafter excising EVERY node on the revocation listcrl(a real-time CRL check across the whole chain)? Zero-heap (bounded BFS). - authority_
after_ revocation - Revocation cascade: after
revokedis revoked, doesagentstill hold authority fromroot_authority? An agent whose only chain ran throughrevokedis now defeated. - delegates_
predicate - The delegation-edge predicate
(delegator, q42:delegatesTo, delegatee). - delegation_
in_ force - Is a delegation temporally in-force at
now?[from, until]Unix-epoch bounds, wherefrom == 0means “no start bound” anduntil == 0means “open-ended”. - delegation_
in_ region - Is a delegation valid in
location? Itsscope_region(0= unbounded / global) must equallocation. Spatial bounding of delegated authority. - has_
delegated_ authority - Does
agenthold authority delegated (transitively) fromroot_authority?Auth(α,p) ∧ Deleg*(α,…,β) → Auth(β,p). - is_
revoked - Is
nodeon the cryptographic revocation listcrl? - revoked_
descendants - Collect, into
out, thecandidatesdefeated by revokingrevoked— held authority before, lost it after. Returns the count. Zero-heap.