Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
static decrypt (ivBuffer, keyBuffer, cipherTextHex) {
let decryptFn = Cipher.createDecipheriv(mode, keyBuffer, ivBuffer)
let cipherText = BufferSafe.from(Utils.bufferFromHexString(cipherTextHex))
let decryptedEntropyBuffer = BufferSafe.concat([decryptFn.update(cipherText), decryptFn.final()])
let decryptedEntropy = verifyDecryptString(decryptedEntropyBuffer)
return decryptedEntropy
}
}