jwt_compact

Module alg

Source
Expand description

Implementations of JWT signing / verification algorithms. Also contains generic traits for signing and verifying keys.

Structs§

Ed25519
Integrity algorithm using digital signatures on the Ed25519 elliptic curve.
Es256
ES256 signing algorithm. Implements elliptic curve digital signatures (ECDSA) on the secp256r1 curve (aka P-256).
Es256k
Algorithm implementing elliptic curve digital signatures (ECDSA) on the secp256k1 curve.
Hs256
HS256 signing algorithm.
Hs384
HS384 signing algorithm.
Hs512
HS512 signing algorithm.
Hs256Key
Signing / verifying key for HS256 algorithm. Zeroed on drop.
Hs256Signature
Signature produced by the Hs256 algorithm.
Hs384Key
Signing / verifying key for HS384 algorithm. Zeroed on drop.
Hs384Signature
Signature produced by the Hs384 algorithm.
Hs512Key
Signing / verifying key for HS512 algorithm. Zeroed on drop.
Hs512Signature
Signature produced by the Hs512 algorithm.
ModulusBitsErrorrsa
Error type returned when a conversion of an integer into ModulusBits fails.
Rsarsa
Integrity algorithm using RSA digital signatures.
RsaParseErrorrsa
Errors that can occur when parsing an Rsa algorithm from a string.
RsaPrivateKeyrsa
Represents a whole RSA key, public and private parts.
RsaPublicKeyrsa
Represents the public part of an RSA key.
RsaSignaturersa
RSA signature.
SecretBytes
Generic container for secret bytes, which can be either owned or borrowed. If owned, bytes are zeroized on drop.
StrongAlg
Wrapper around a JWT algorithm signalling that it supports only StrongKeys.
StrongKey
Wrapper around keys allowing to enforce key strength requirements.
WeakKeyError
Error type used for fallible conversion into a StrongKey.

Enums§

ModulusBitsrsa
Bit length of an RSA key modulus (aka RSA key length).

Traits§

SigningKey
Signing key for a specific signature cryptosystem. In the case of public-key cryptosystems, this is a private key.
VerifyingKey
Verifying key for a specific signature cryptosystem. In the case of public-key cryptosystems, this is a public key.