- Auth module for Derby 0.6
- Email/Password and Passport OAuth providers
- Uses projections (data stored in one collection)
- All routes start with '/auth/*'
- Bootstrap 3 components (change email, change password, login, logout, recover password, register, reset password)
- Custom components (forms) are supported by parse-request hooks
- Routes for confirmation of registration and email change
- Hooks (sending emails, parse-request, request, response, error)
- Bcrypt (default), Scrypt and Sha-1 encryption
- Powerful server-side API
- No jQuery dependency
- Tests
- Influenced by derby-auth
- Does not work with Derby 0.3 and 0.5
- No built-in access control (use share-access)
- You have only userId in '_session.userId', and you should subscribe to user in router by yourself, example
- set
{encryption: 'sha-1', hashField: 'passwordHash'}
in options
npm install derby-login
var derbyLogin = require('derby-login');
Step 2. Options (take a look at default options)
var options = {};
.use(derbyLogin.middleware(backend, options))
- derby-login-example example app with auth
Copyright (c) 2014 Vladimir Makhaev
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.