EncryptJweInput
EncryptJweInput
Input to encryptCompactJwe.
ts
interface EncryptJweInput {
readonly publicKey: CryptoKey;
readonly plaintext: Uint8Array;
readonly algorithm: JweAlgorithm;
readonly encryption: JweEncryption;
readonly header?: JsonObject;
readonly limits?: Partial<JoseLimits>;
}Properties
readonlypublicKey:CryptoKey— An RSA-OAEP/SHA-512 public key withencryptusage, 2048–8192 bits.readonlyplaintext:Uint8Array— Payload bytes; text encoding is the caller's decision.readonlyalgorithm:JweAlgorithm— Explicit key-management algorithm.readonlyencryption:JweEncryption— Explicit content-encryption algorithm.readonlyheader?:JsonObject— Additional protected JSON data.algandenc, if supplied, must agree. No defaulttyp.readonlylimits?:Partial<JoseLimits> — Existing JOSE bounds;maxPayloadBytesalso bounds plaintext/ciphertext andmaxSignatureBytesbounds the encrypted CEK.