Skip to main content

Module rsa_pss_verify

Module rsa_pss_verify 

Source
Expand description

RSA-PSS verification-key minting (RFC 8017 §8.1), as the Web Cryptography API serves it.

The variant binds the digest at mint (WebCrypto’s RsaHashedImportParams), and — unlike WebCrypto, whose saltLength is a per-operation parameter — the salt length binds at mint too: a granted key verifies exactly one PSS parameterization, so salt-length confusion is unrepresentable (see README.md, “Design notes”). The MGF1 digest is the message digest, as WebCrypto fixes it. Keys report algorithm-name "RSA-PSS", the variant’s digest, and the modulus length.

Functions§

import_verifying_key_jwk
Import a public key as an RSA public JWK (kty: "RSA", with n and e); see import-verifying-key-spki for salt-length, and mac-key.export-key-jwk for the package-wide JWK contract. An alg member, when present, must be the variant’s JOSE alg ("PS256", "PS384", or "PS512").
import_verifying_key_spki
Import a public key as an X.509 SubjectPublicKeyInfo (DER). Admission follows the family contract (see rsa).

Type Aliases§

Error
RsaVariant
VerifyingKey