ic_auth_protocol_types/limits.rs
1//! Structural protocol ceilings shared by validation and bounded transport.
2//! Hosts may impose tighter policy; transport allocation budgets are separate.
3
4/// Maximum role grants in a credential or delegation certificate.
5pub const MAX_GRANTS: usize = 16;
6/// Maximum scopes in a role grant.
7pub const MAX_SCOPES_PER_GRANT: usize = 32;
8/// Maximum requested scopes in a receiver session.
9pub const MAX_SESSION_SCOPES: usize = 16;
10/// Maximum bytes in a role or scope label.
11pub const MAX_LABEL_BYTES: usize = 64;
12/// Hard cap on signed claims, independent of outer transport limits.
13pub const MAX_CLAIMS_BYTES: usize = 65_536;