loopback-passport-jwt
v1.0.0
Published
Loopback module with passport for local or social login and JWT (no session)
Downloads
3
Maintainers
Readme
loopback-passport-jwt
Loopback module with passport for local or social login and JWT (no session).
See the example of use: https://github.com/miyoda/loopback-passport-jwt-standalone#readme
##config Use a config file like this and delete unnecesary integrations
{
"authPath": "/auth"
,"authOpts": {
"scope": []
}
,"jwt": {
"secretOrKey": "ssssssssssssh",
"expiresInSeconds": 30
}
,"facebook": {
"clientID": "--------",
"clientSecret": "---------",
"profileFields": ["id", "displayName", "photos", "email"],
"scope": []
}
,"google": {
"clientID": "------",
"clientSecret": "------"
}
,"instagram": {
"clientID": "------",
"clientSecret": "------"
}
,"local": {
"usernameField": "username"
}
}
##facebook Add passport-facebook dependency
npm install --save passport-facebook Follow passport-facebook readme for obtain secretKey
##google Add passport-google dependency
npm install --save passport-google Follow passport-google readme for obtain secretKey
##instagram Add passport-instagram dependency
npm install --save passport-instagram Follow passport-facebook readme for obtain secretKey
##local Add passport-local dependency
npm install --save passport-local Follow passport-facebook readme for obtain secretKey
##TODO It's not finished! *Config apikeys *TEST google integration *TEST instagram integration *Implement local integration