@dotsenkodanylo/quick-encrypt
v1.1.4
Published
Subset of encryption tools for variety of data types.
Downloads
2
Maintainers
Readme
Quick En-Crypt
Small package dependent on Tweetnacl encryption library that streamlines some encryption/decryption for a few JS-centric data types.
Examples:
fs.readFile('file.bin', function (err, data) {
// Decode the buffer returned by the `readFile` method.
let decrypted = decryptJson(data, key);
// Pass the decrypted encoding to a new Buffer.
let buffer = Buffer.from(decrypted);
// Create file with the encoding.
fs.writeFileSync('assets/file.txt', buffer, function (err) {
console.log('Success!');
});
});