Skip to main content

Crate moq_token

Crate moq_token 

Source
Expand description

JWT token generation and validation for MoQ authentication.

Create and verify JWT tokens used for authorizing publish/subscribe operations in MoQ. Tokens specify which broadcast paths a client can publish to and consume from.

See Claims for the JWT claims structure and Key for key management.

Structs§

Claims
The payload of a token: a root, plus the publish/subscribe prefixes granted beneath it.
Jwk
JWK, almost to spec (https://datatracker.ietf.org/doc/html/rfc7517) but not quite the same because it’s annoying to implement.
Key
A validated key, ready to sign and verify tokens.
KeyId
A validated key identifier (kid) that is safe for use in file paths and URLs.
KeySet
JWK Set to spec https://datatracker.ietf.org/doc/html/rfc7517#section-5
Permissions
The access a Claims grants at a specific path, with every prefix rebased so it is relative to that path.
RsaAdditionalPrime
Additional prime information for multi-prime RSA keys.
RsaPrivateKey
RSA private key parameters.
RsaPublicKey
RSA public key parameters.
Scope
The immutable ceiling on what a key may grant, embedded in its JWK.

Enums§

Algorithm
A subset of jsonwebtoken algorithms.
EllipticCurve
Supported elliptic curves for EC and OKP key types.
Error
Top-level error type for moq-token.
KeyError
Errors related to key configuration and cryptographic operations.
KeyIdError
KeyMaterial
https://datatracker.ietf.org/doc/html/rfc7518#section-6
KeyOperation
Cryptographic operations that a key can perform.

Type Aliases§

Result