MencapsulateKey
Bun

method

crypto.webcrypto.SubtleCrypto.encapsulateKey

encapsulationAlgorithm: AlgorithmIdentifier,
encapsulationKey: CryptoKey,
extractable: boolean,
usages: KeyUsage[]
): Promise<EncapsulatedKey>;

Referenced types

interface CryptoKey

interface AesDerivedKeyParams

interface KmacImportParams

type KeyUsage = 'decapsulateBits' | 'decapsulateKey' | 'decrypt' | 'deriveBits' | 'deriveKey' | 'encapsulateBits' | 'encapsulateKey' | 'encrypt' | 'sign' | 'unwrapKey' | 'verify' | 'wrapKey'