Encrypte & Decrypte string in Node.js

I have tried to encrypte and decrypte string in Node.js recently.
There has many code examples at Internet, eg:

Run it in console commond but the following error has occurred. Ummm….,that is weird,may be ‘base64’ encoding will not working with ‘aes192’..?
Anyway, the following code works fine for me.

And the console log.

Related Post

Write a Heroku Scheduler batch for MangoDB+Salesfo... In previous post,I had shared how to 《Access Salesforce data via APIs(JSForce) from Outside Service》. In this post I will share about how to write a Heroku Scheduler batch for synchronizing MangoDB data to Salesforce with Node.js, like the below outline picture. ※I have no doubt that there hav...
Awesome Node.js development environment with Herok... As we know,Heroku enables developers to build and run Node.js apps on it,and the most important,it is FREE. Today I will try to setup an awesome Node.js development environment and deployment with Cloud9 and Heroku. Of course, we need to sign up first. 1.Sign up 1.https://c9.io/ 2.https://www...

Post Tagged with , , , ,