code: function readKey(key, next) {
      var keytype = path.extname(key) === '.pub' ? 'public' : 'private';
      fs.readFile(key, function (err, data) {
        if (err) {
          return next(err);
        }
  
        keyinfo[keytype] = {
          raw: data.toString(),
          base64: data.toString('base64'),
          name: path.basename(key),
          path: key
        };
  
        next();
      });
    }
docs: Helper function which populates a given field (`public`, `private`) in the keys info to be returned.