@pan-os/cerberus
Version:
security wrapper to protect routes dynamically with heimdall structure
49 lines (36 loc) • 1.12 kB
Markdown
# Cerberus
[](https://app.wercker.com/project/byKey/fab3b248ad74be9615d8af89d63f7e02)
A security wrapper to protect routes dynamically with Heimdall structure.
## Motivation
The whole idea behind this project is to split concerns betweens API structure to handle auth and strategies separately.
## Installation
TBD
### Requirements
TBD
* Restify
## Usage
```javascript
/**
* Module Dependencies
*/
const { protect: withCerberus } = require('cerberus');
/**
* Pseudo microservices
*/
const {
terms, auth, config, user,
} = require('../services');
module.exports = (server) => {
// Attach microservices to /
Heimdall.attachMicroservice(server, withCerberus(config));
};
```
## Available Strategies
* Local Strategy (login, senha)
* GPlus
* Facebook
## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
## License
[MIT](https://choosealicense.com/licenses/mit/)