1.0.1 • Published 6 years ago

lean-auth v1.0.1

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

lean-auth

NPM Version Build Status

features

  • username/password login
  • ldap login
  • email verification
  • password recovery
  • role/permission management

api

const {Auth} = require("lean-auth")

let auth = new Auth({database: "mysql://user:passwd@localhost/db"})

auth.sync().then(function(){
    auth.createUser({
        name: name,
        email: email,
        password: password
    })
})

auth.login({name: name}, password)