Module providing Passport.js auth for express
npm install core.io-express-auth
#### Routes
- GET /login: Show login form.
- POST /login: Handle local strategy login.
- GET /logout: Destroy session.
- GET /signup: Show signup form.
- POST /signup:
- GET /auth/:
- POST /register: 'UserController.create',
- POST /logout: 'AuthController.logout',
- POST /auth/local: 'AuthController.callback',
- POST /auth/local/:action: 'AuthController.callback',
- POST /auth/:provider: 'AuthController.callback',
- POST /auth/:provider/:action: 'AuthController.callback',
- GET /auth/:provider: 'AuthController.provider',
- GET /auth/:provider/callback: 'AuthController.callback',
- GET /auth/:provider/:action: 'AuthController.callback'
#### Custom Error views
If our sub-app has the following view structure:
```
.
├── views
│ ├── error-layout.ejs
│ ├── 401.ejs
│ └── 403.ejs
The error view will be rendered with the following locals:
`js`
let locals = {
isErrorView: true,
status: status,
message: err.message,
error: err
};