Declaraciones públicas de zig/src/jwt.zig (spire-zig (SDK consumido)).
apps/docs/generated/zig/spire.jsonPágina generada desde
spire@spire-0.2.0-XvnrRek1BgCX4Bh8miuITCQgkn0FqeQrYYE3goFfDcQd (zig/src/root.zig). No se edita a mano:bun run docs:genla regenera ybun run docs:checkfalla si difiere.
Verificación del actor (dec-0119 §5.2): el sobre lleva el access JWT del
usuario, no un claim del emisor. Formato de dec-0113 §1: JWS compacto,
alg: EdDSA (Ed25519), typ: at+jwt, kid = thumbprint RFC 7638;
claims iss, aud (styx), sub, sid, iat, exp, jti.
Parser de entrada no confiable (dec-0117 I5): todo acotado en la pila,
sin unreachable, sin reservas en el heap (JSON sobre un
FixedBufferAllocator de tamaño fijo).
jwt.MAX_TOKEN_LENconst · línea 16
pub const MAX_TOKEN_LEN: usize = 8192Sin ///.
jwt.MAX_HEADER_JSONconst · línea 17
pub const MAX_HEADER_JSON: usize = 512Sin ///.
jwt.MAX_CLAIMS_JSONconst · línea 18
pub const MAX_CLAIMS_JSON: usize = 4096Sin ///.
jwt.MAX_KEYSconst · línea 19
pub const MAX_KEYS: usize = 4Sin ///.
jwt.MAX_STRconst · línea 20
pub const MAX_STR: usize = 256Sin ///.
jwt.Errorconst · línea 22
pub const Error = error{ Malformed, UnsupportedAlgorithm, WrongType, UnknownKey, BadSignature, WrongIssuer, WrongAudience, Expired, NotYetValid, MissingClaim, }Sin ///.
jwt.Actortype · línea 37
pub const Actor = structLo que el receptor sabe del actor tras verificar. Copias fijas: no dependen del buffer del sobre.
jwt.Actor.subfn · línea 44
pub fn sub(a: *const Actor) []const u8Sin ///.
jwt.Actor.sidfn · línea 47
pub fn sid(a: *const Actor) []const u8Sin ///.
jwt.thumbprintfn · línea 58
pub fn thumbprint(public_key: [32]u8) [43]u8Thumbprint RFC 7638 de una clave OKP/Ed25519, en base64url sin padding.
jwt.Verifiertype · línea 70
pub const Verifier = structSin ///.
jwt.Verifier.addKeyfn · línea 77
pub fn addKey(self: *Verifier, raw: [32]u8) error{ WeakPublicKey, TooManyKeys }!voidSin ///.
jwt.Verifier.verifyfn · línea 84
pub fn verify(self: *const Verifier, token: []const u8, now_s: i64) Error!ActorSin ///.
jwt.testingtype · línea 196
pub const testing = structSin ///.
jwt.testing.mintfn · línea 197
pub fn mint(buf: []u8, kp: Ed25519.KeyPair, claims_json: []const u8, typ: []const u8) ![]const u8Sin ///.