pub struct Admission { /* private fields */ }Expand description
A successfully admitted skill: the verified manifest plus the capabilities the broker will enforce at call time.
Only verify_admission makes one. The fields are private, so
holding an Admission proves the manifest passed every gate, and its
capability set cannot be widened afterwards.
Implementations§
Source§impl Admission
impl Admission
Sourcepub const fn signer(&self) -> &[u8; 32]
pub const fn signer(&self) -> &[u8; 32]
The trust root whose key verified the manifest’s signature: the skill’s signing identity, as distinct from its name.
Sourcepub fn signer_fingerprint(&self) -> String
pub fn signer_fingerprint(&self) -> String
The signing identity as a stable display form: the SHA-256 of the verifying key, lowercase hex. Two skills share it exactly when the same key signed both, whatever their names.
Sourcepub const fn capabilities(&self) -> &HashSet<CapabilityName>
pub const fn capabilities(&self) -> &HashSet<CapabilityName>
The declared capabilities that call-time checks enforce.
Sourcepub fn check_call(&self, capability: &CapabilityName) -> Result<(), Error>
pub fn check_call(&self, capability: &CapabilityName) -> Result<(), Error>
Check a capability at call time. Returns Ok(()) if the
capability was declared in the manifest; otherwise a typed
denial.
§Errors
Returns Error::UndeclaredCapability if the capability was
not declared in the manifest.