Thursday, 13 April 2017

Encrypt CryptoJS without special characters

using nodejs I am trying to generate an unique URL for user to conform email address. From that URL user will be able to verify the email account by decrypting the ciphertext and comparing ciphertext data with database . I am using CryptoJS to generate the url.

let url = 'http://localhost:4000/newUser/get/'+ciphertext ;

Problem is that in ciphertext, it contains forward slash " / " eg:

http://localhost:4000/newUser/get/U2FsdGVkX189ZNKKQrYgqU90DDwkl/W3hRTSGO1yvUMaDilPJmz9YYI3d1/E3i9C

Router is processing " / " on the URL, thus router is searching for the directory that is actually part of ciphertext. If there is any solution for not including " / " or special characters in ciphertext, please help. Thanks in advance.



via Shashank B

No comments:

Post a Comment