Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
var crypto = require('crypto');
var cipher = crypto.createCipher( process.argv[2], 'tacos' );
//aes-gcm 256
//key size must be 32
var cipher = crypto.createCipheriv('aes-256-gcm', '3zTvzr3p67VC61jmV54rIYu1545x4TlY', 'X6sIq117H0vR');
var cipher = crypto.createCipher('aes-256-gcm', '3zTvzr3p67VC61jmV54rIYu1545x4TlY');
//aes-gcm 128
//key size must be 16
var cipher = crypto.createCipheriv('aes-128-gcm', '3zTvzr3p67VC61jm', 'X6sIq117H0vR');
var cipher = crypto.createCipher('aes-128-gcm', '3zTvzr3p67VC61jm');
console.log( );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment