bitpay/bitcore — pull request #308 by ryanxcharles (2014-04-30 19:21:45+00:00)
Title: Symmetric encryption

Can encrypt/decrypt a message with AES encryption. The format of the encrypted message is:

[IV] [ciphertext]

There only one caveat ... since browserify doesn't support createCipheriv, I've had to import crypto-js. And since I need to control the iv and encodings and what not, I have had to include the entire crypto-js library for this to work, which bumps up the size of bundle.js by 50KB. For that reason we may want to do something different.

However, symmetric encryption is a necessary prerequisite for asymmetric encryption, which is the next goal.