- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 06:37 AM
HI Team
Issue : Imported the CryptoJS AES library in script include and facing below error " Evaluator: org.mozilla.javascript.EcmaError: "Link to Lib : https://cdnjs.cloudflare.com/ajax/libs/crypto-js/4.0.0/aes.min.js
Executed Below Script in Scoped App :
var wsClient = new x_snc_customEncryption.CryptoJS();
var enc_result = wsClient.AES.encrypt(current.short_description, "888888888888888888", {
iv: '888888888888888888'
});
gs.info(enc_result);
Kindly assist in resolving issue ...as client side encryption and decryption is achievable but facing issue at server side.
Thanks
Manasa
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 09:38 AM
It will save you time and grief if you just buy it. I have gone down this road before DB Encryption and ultimately DB Encryption will save a lot of work and support headaches.
But if you really want to go there this is what I did 4 years ago before DB Encryption.
https://community.servicenow.com/community?id=community_question&sys_id=d0394fe1db5cdbc01dcaf3231f9619d5&view_source=searchResult
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 06:47 AM
Hi
on server-side JavaScript cannot load additional JavaScript libraries from Internet. So if you want to load a JavaScript file on the server you have to include all additional required JavaScript files. Basically it should be possible to include all JavaScript files into one file, but it depends on how they are implemented.
And please consider that on server-side only ECMA 5.0 is possible (see https://docs.servicenow.com/bundle/quebec-application-development/page/script/JavaScript-engine-upgr...)
Kind regards
Maik
If my answer replied your question please mark appropriate response as correct so that the question will appear as resolved for other users who may have a similar question in the future.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 07:01 AM
What is your overall goal that you are trying to achieve? Its been a while since I have seen a need for this since SNC released DB encryption.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 09:08 AM
Was trying to implement encryption without the need of the plugin ..
Thanks
Manasa

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2021 09:38 AM
It will save you time and grief if you just buy it. I have gone down this road before DB Encryption and ultimately DB Encryption will save a lot of work and support headaches.
But if you really want to go there this is what I did 4 years ago before DB Encryption.
https://community.servicenow.com/community?id=community_question&sys_id=d0394fe1db5cdbc01dcaf3231f9619d5&view_source=searchResult