The CreatorCon Call for Content is officially open! Get started here.

Facing challenge to bundle the Crypto-js.js file.

guptashalini041
Kilo Contributor

I am trying to use the crypto.js file of node.js in servicenow. As servicenow doesnot support the node.js so I am trying to bundle the crypto.js using the below URL so that I can use this js in script include.

https://www.youtube.com/watch?v=BUKF2eKL8Gk#t=646

Speaker of the above video is Josh Nerius, Developer Evangelist at ServiceNow. 

I tried to follow all the steps in this video but steps are not clear and unable to generate the bundle file.

Can someone help in creating the bundle file of crypto.js?

Josh Nerius: If you are on community, Can you please share the crypto.js file.

Thank you.

 

 

 

6 REPLIES 6

Community Alums
Not applicable

I can't thank you enough @Miguel Donayre 
This helped me a lot, I was able to adapt your script include to my needs and encryption requirements, thank you so much!

gautam13
Tera Contributor

Thanks, Miguel! This helps out a ton!

I'm getting an error when I execute 

var sig = (x_fise_nodejs.CryptoJS.HmacSHA512(requestVars, apiKey));

but works fine when I do


var sig = (x_fise_nodejs.CryptoJS.HmacSHA256(requestVars, apiKey));

Does your script work only with SHA256? If so, why?