Comments (4)
I can confirm I am having the same problem. Did you ever figure out the issue?
It appears to me that the UserController's "me" action isn't being called for some reason, even if you route it directly. I've tried calling "sails.log.info()" in the "me" action, and nothing is being logged. I've also tried editing the response passed in to res.ok(), and that didn't change anything either.
from sails-auth.
I found a solution!
Use this:
https://github.com/langateam/sails-permissions
Just use the files from sails-permission code!
I had problems using sails-auth only, but now everything works like charm :)
(even /user/me) ;)
from sails-auth.
Got the same problem =/
from sails-auth.
+1
In my case, deserializeUser
is never called. So the user object is not attached to req.user
.
Adding the passport
policy for UserController
in config/policies.js
will invoke deserializeUser
, and the user will then be attached, but I'm not sure whether if this is the right way to do it.
In config/policies.js
:
UserController: {
me: ['passport']
}
from sails-auth.
Related Issues (20)
- Is the project still active? HOT 1
- sails.getBaseURL() is deprecated. HOT 14
- Deprecated project? HOT 1
- Broken with sails 0.12.3 HOT 2
- unique: true works bad with sails-mongo. HOT 1
- LDAP auth HOT 2
- action=login error HOT 2
- login sample HOT 1
- NPM HOT 8
- LinkedIn Passport provider saved as null
- Why did you remove the "generator"? HOT 1
- Login when registerig HOT 1
- "Remember Me" functionality HOT 2
- How to redirect to a page if the login fails?
- Cannot find module when files are pulled from repo HOT 1
- issue with sails 0.12.14
- Error out of the box HOT 4
- warn: Action middleware (POLICY: passport) was bound to a target `auth/*` that doesn't match any registered actions. HOT 2
- Argon2 Support?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sails-auth.