0

I wondered if you can help with an issue when using this library in the Runscope JavaScript interpreter(V8-compatible (version 3.28), sandboxed JavaScript interpreter).

I think it's happening because the JSEncrypt code is expecting a browser?

Error: [Uncaught ReferenceError: ASN1 is not defined]

Would anyone know how to work around such an issue?

A similar issue has been encountered on Rhino

Thanks for any suggestions.

user45097
  • 177
  • 1
  • 3
  • 12
  • I've updated JSEncrypt as documented here: https://github.com/travist/jsencrypt/issues/21. Seems to have resolved the asn1 error above. Although now when I call `var enc = crypt.encrypt(text);` it returns false. – user45097 Feb 09 '17 at 12:03

1 Answers1

0

Must have missed one of the changes when I first attempted updating JSEncrypt as documented here: https://github.com/travist/jsencrypt/issues/21.

Can confirm encryption is working now.

Community
  • 1
  • 1
user45097
  • 177
  • 1
  • 3
  • 12