pub struct VerifiedPortableClaims { /* private fields */ }Expand description
Claims authenticated by one complete portable proof verifier at a host clock. Read-only and not deserializable; decoding or editing claims cannot forge this result. It is not a session, enrollment approval or resource authorization. Consume it under the same host transaction/authority snapshot as verification; matching time alone does not establish that authority is still current.
use ic_auth::portable::VerifiedPortableClaims;
use ic_auth_protocol_types::PortableClaims;
fn forge(claims: PortableClaims) -> VerifiedPortableClaims { claims.into() }Implementations§
Source§impl VerifiedPortableClaims
impl VerifiedPortableClaims
Sourcepub fn session_expires_at_ns(
&self,
request: &SessionRequest,
role: &AuthRole,
default_ttl_secs: u64,
max_ttl_secs: u64,
) -> Result<u64, SessionRequestError>
pub fn session_expires_at_ns( &self, request: &SessionRequest, role: &AuthRole, default_ttl_secs: u64, max_ttl_secs: u64, ) -> Result<u64, SessionRequestError>
Exclusive lease deadline for admission at this verification snapshot. Proof expiry limits new admission, not the resulting lease. The signed login deadline and protected key/enrollment deadlines cap the lease. Persist this result once; refreshing enrollment never extends stored leases. The role comes from protected receiver configuration, never the request. Requested scopes must narrow that role’s grant; other roles cannot supply missing scopes. This does not check replay, revocation or current authority after verification, and does not create or authorize a session.
pub fn claims(&self) -> &PortableClaims
Sourcepub fn fingerprint(&self) -> [u8; 32]
pub fn fingerprint(&self) -> [u8; 32]
Canonical claims digest, independent of alternate proof/signature bytes.