Expand description
RSA-OAEP encryption-key minting (RFC 8017 §7.1), as the Web Cryptography API serves it: the public half of key transport.
The variant binds the digest at mint (WebCrypto’s
RsaHashedImportParams); the MGF1 digest is the same digest, as
WebCrypto fixes it. Keys report algorithm-name "RSA-OAEP", the
variant’s digest, and the modulus length.
Admission tightens the family window on both ends: the modulus must
be 2048–8192 bits, error.invalid-key outside — encryption creates
future artifacts, so unlike signature verification there is no
legacy tier below 2048 (see README.md, “Design notes”). The
plaintext bound follows from the mint: modulus bytes minus twice the
digest length minus 2.
Functions§
- import_
encryption_ key_ jwk - Import a public key as an RSA public JWK (
kty: "RSA", withnande). Analgmember, when present, must be the variant’s JOSE alg ("RSA-OAEP-256","RSA-OAEP-384", or"RSA-OAEP-512"). Seemac-key.export-key-jwkfor the package-wide JWK contract. - import_
encryption_ key_ spki - Import a public key as an X.509 SubjectPublicKeyInfo (DER).
Admission follows the family contract (see
rsa) plus the window above.