40 Clean Password: Memz

// Simple encryption example const encryptPassword = (password) => const iv = crypto.randomBytes(16); const key = crypto.randomBytes(32); // 256-bit key const cipher = crypto.createCipheriv('aes-256-cbc', key, iv); let encrypted = cipher.update(password, 'utf8', 'hex'); encrypted = Buffer.concat([encrypted, cipher.final()]); return iv.toString('hex') + ':' + key.toString('hex') + ':' + encrypted.toString('hex');

This is the original version of Bvckup. It was written for Windows XP, last updated in 2010 and it's now well behind times. Use at your own risk, basically.
It has been superseded by Bvckup 2 - a faster and significantly more refined revision of the same idea. Have a look.
http://www.bvckup2.com