userbox
v0.2.0
Published
A really simple way to store user records in a JSON file.
Downloads
3
Readme
userbox
A really simple file-based auth system for node.js; persists user records in a JSON file, and includes password hashing/checking by default.
var userBox = require('userbox')('path/to/file.json')
userBox.create('<user_id>','<clearTextPass>',{<profile>}) //adds user to file with hashed pass
userBox.authenticate('<user_id>','<clearTextPass>') //returns boolean
userBox.read('<user_id>') //returns user record
userBox.update('<user_id>',['<clearTextPass>'],[{<profile>}]) //you guessed it
userBox.delete('<user_id>') //yep