-
Notifications
You must be signed in to change notification settings - Fork 296
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
Login redirect loop #2
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
… it can lead to errors whe using utf8. Optimization is left for the user if he needs any
…er') instead the models alias to make sure the cookie will work accross subdomains out of the box that share the same user data but use another model alias
…g login on the add() action.
…ment passing to action on users controller.
…nt to fix redirect to invalid location after registration of user.
…ser, to the loginRedirect setting on Auth.
The user model is used by the auth component to know where in the session to look for auth data. using $controller->modelClass as a default means that the auth component looks in a different place for each controller and therefore has the potential to invoke a redirect loop where (example using an empty install): you login - users controller, sessionKey in the auth component is set to "Auth.User" derived from the userModel you're redirected to the home. you re-land at home - pages controller sessionKey in the auth component is set to "Auth.Page" dervied from the userModel you're redirected to login. irgo: / -> /users/users/login -> / -> .. ad infinitum After correcting this error, it is apparent that if you're logged in but do not have access the auth component will redirect you to a "safe" url which is assumed to be the home. If you have NOT granted access to / this will again invoke a redirect loop this time / -> / as the auth component tries to redirect you away from the page you don't have acces for.
changes integrated into correct branch. |
Closed
steinkel
pushed a commit
that referenced
this pull request
Jan 18, 2018
Remove unnecessary translation strings
This pull request was closed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This fix will allow the second redirect loop to be addressed. Incase github flips out - this is intended to be against feature/refactor.
Edit: github evidently has problems if you change the pull request target please disregard the listed commits below and see only https://github.com/AD7six/users/commit/750021c2b0ffbf57772cd851673dbc15336348de