package
Encrypt/Decrypt the values of a given object
npm install secure-keysGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
A simple module that encrypts/decrypts the keys of a given object
npm i secure-keys --savevar SecK = require('secure-keys');
var sec = new SecK({
secret: 'BEGIN RSA', // Text of key used for encrypting/decrypting
format: JSON, // optional (defaults to JSON): An object with `stringify` and `parse` methods
alg: 'aes-256-ctr' //optional (this is default) Algorithm to use for encrypt/decrypt
});
var encryptedObj = sec.encrypt({
myConfig: 'values',
needTo: 'be safe'
});
var decryptedObj = sec.decrypt(encryptedObj);MIT
This code was yanked out of work by
@indexzero for
nconf