/** * Look up a key-management descriptor. Throws * {@link ErrorCode.UNSUPPORTED_ALGORITHM} for anything not in the table, * including the deliberately-excluded `RSA1_5`. * * @param {string} alg * @returns {KeyManagementDescriptor} */ export function lookup(alg: string): KeyManagementDescriptor; /** Every JWE `alg` identifier this package supports. */ export const SUPPORTED: readonly string[]; export type KeyManagementDescriptor = { /** * The JOSE `alg` identifier. */ alg: string; /** * Wrap family. */ kind: "rsa" | "aeskw" | "ecdh" | "dir"; /** * OAEP hash (RSA family only). */ hash?: "sha1" | "sha256" | undefined; /** * AES key-wrap KEK size in bits (AES-KW only). */ bits?: number | undefined; /** * CEK wrap step for ECDH-ES * (`null` = ECDH-ES direct, the derived secret *is* the CEK). */ wrap?: "A128KW" | "A256KW" | null | undefined; };