pbkdf2-password.js
function genSalt(opts, cb) {
    crypto.randomBytes(saltLength, function(err, buf) {
      opts.salt = buf;
      cb(err, opts);
    });
  }
function genSalt(opts, cb) {
    crypto.randomBytes(saltLength, function(err, buf) {
      opts.salt = buf;
      cb(err, opts);
    });
  }
function genSalt ( opts , cb ) { crypto . randomBytes ( saltLength , function ( err , buf ) { opts . salt = buf ; cb ( err , opts ) ; } ) ; }
Generates a new salt

@api private
@param {Object} opts The options (where the new password will be stored)
@param {Function} cb The callback
Generates a new salt