Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I hope I can get the client used by the current user in findForPassport() and validateForPassportPasswordGrant(). #1007

Closed
codeyifei opened this issue Apr 22, 2019 · 1 comment

Comments

@codeyifei
Copy link

I hope I can get the client used by the current user in findForPassport() and validateForPassportPasswordGrant().

In some more complex applications, users can log in through different clients, but in some cases, the login logic of different clients cannot be the same.

For example, a user can use both WeChat and App customers at the same time, but WeChat uses OpenID to log in, and App uses user name and password to log in. At this time, it is necessary to judge whether the client used when logging in is WeChat or App. It seems that you can only use request('client_id') to make judgments. I hope that Passport can add corresponding methods that can get the current client instance before, such as Passport::getCurrentClient()

@driesvints
Copy link
Member

Please see #882

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants