@pan-os/cerberus
Advanced tools
Comparing version 1.0.3 to 1.0.4
@@ -58,3 +58,4 @@ /** | ||
* | ||
* @param {*} microService The microsservice to wrap. | ||
* @param {Object} services The microsservice to wrap. | ||
* @returns {Array} protected microService routes | ||
*/ | ||
@@ -69,4 +70,4 @@ const protect = (services) => { | ||
await validate(req); | ||
} catch (exception) { | ||
return next(exception); | ||
} catch (error) { | ||
return next(error); | ||
} | ||
@@ -73,0 +74,0 @@ |
{ | ||
"name": "@pan-os/cerberus", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "security wrapper to protect routes dynamically with heimdall structure", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "yarn test" | ||
"test": "xo && ava --tap | tap-nyan" | ||
}, | ||
@@ -30,4 +30,24 @@ "repository": { | ||
"passport-facebook": "^2.1.1", | ||
"restify-errors": "^6.1.1" | ||
"passport-local": "^1.0.0", | ||
"restify-errors": "^6.1.1", | ||
"tap-nyan": "^1.1.0" | ||
}, | ||
"devDependencies": { | ||
"ava": "^1.0.0-beta.8", | ||
"xo": "^0.23.0" | ||
}, | ||
"xo": { | ||
"extends": [ | ||
"prettier" | ||
], | ||
"globals": [ | ||
"it", | ||
"describe", | ||
"before" | ||
], | ||
"rules": { | ||
"prefer-promise-reject-errors": 0, | ||
"no-use-extend-native/no-use-extend-native": 0 | ||
} | ||
} | ||
} |
@@ -1,2 +0,3 @@ | ||
# Cerberus ![CI status](https://img.shields.io/badge/build-passing-brightgreen.svg) | ||
# Cerberus | ||
[![wercker status](https://app.wercker.com/status/fab3b248ad74be9615d8af89d63f7e02/m/master "wercker status")](https://app.wercker.com/project/byKey/fab3b248ad74be9615d8af89d63f7e02) | ||
@@ -3,0 +4,0 @@ A security wrapper to protect routes dynamically with Heimdall structure. |
const FacebookStrategy = require('passport-facebook').Strategy; | ||
module.exports = new FacebookStrategy({ | ||
clientID: process.env.FACEBOOK_APP_ID, | ||
clientSecret: process.env.FACEBOOK_APP_SECRET, | ||
callbackURL: process.env.FACEBOOK_APP_CALLBACK, | ||
clientID: process.env.FACEBOOK_APP_ID || 'x', | ||
clientSecret: process.env.FACEBOOK_APP_SECRET || 'x', | ||
callbackURL: process.env.FACEBOOK_APP_CALLBACK || 'x', | ||
}, | ||
@@ -8,0 +8,0 @@ (accessToken, refreshToken, profile, done) => { |
@@ -1,2 +0,2 @@ | ||
const localStrategy = require('./localStrategy'); | ||
const localStrategy = require('./local-strategy'); | ||
const facebookStrategy = require('./facebook'); | ||
@@ -3,0 +3,0 @@ |
Sorry, the diff of this file is not supported yet
140853
14
106
49
6
2
+ Addedpassport-local@^1.0.0
+ Addedtap-nyan@^1.1.0
+ Addedansi-styles@2.2.1(transitive)
+ Addedargparse@1.0.10(transitive)
+ Addedchalk@1.1.3(transitive)
+ Addedduplexer2@0.1.4(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedesprima@4.0.1(transitive)
+ Addedevents-to-array@1.1.2(transitive)
+ Addedhas-ansi@2.0.0(transitive)
+ Addedhas-flag@1.0.0(transitive)
+ Addedjs-yaml@3.14.1(transitive)
+ Addedpassport-local@1.0.0(transitive)
+ Addedsprintf-js@1.0.3(transitive)
+ Addedsupports-color@2.0.03.2.3(transitive)
+ Addedtap-nyan@1.1.0(transitive)
+ Addedtap-parser@3.0.5(transitive)