(decapsulationKey, ciphertext)
| 212 | } |
| 213 | |
| 214 | function mlKemDecapsulate(decapsulationKey, ciphertext) { |
| 215 | if (getCryptoKeyType(decapsulationKey) !== 'private') { |
| 216 | throw lazyDOMException(`Key must be a private key`, 'InvalidAccessError'); |
| 217 | } |
| 218 | |
| 219 | return jobPromise(() => new KEMDecapsulateJob( |
| 220 | kCryptoJobWebCrypto, |
| 221 | getCryptoKeyHandle(decapsulationKey), |
| 222 | undefined, |
| 223 | undefined, |
| 224 | undefined, |
| 225 | undefined, |
| 226 | ciphertext)); |
| 227 | } |
| 228 | |
| 229 | module.exports = { |
| 230 | mlKemExportKey, |
nothing calls this directly
no test coverage detected
searching dependent graphs…