How Using function CryptoJS.HmacSHA256 in Oracle Service Bus Javascript
Hi Guys,
We need to encrypt some JSon payload using CryptoJS.HmacSHA256 .
How to implement that encrypt inside OSB javascript
already try using this code, but getting error "OSB JavaScript action failed: ReferenceError: "CryptoJS" is not defined"
var hash = CryptoJS.HmacSHA256(process.body, process.ServerKey)
var signatureId = CryptoJS.enc.Base64.stringify(hash).replace(/\n+$/, '')
process.signatureId = signatureId;