-
Notifications
You must be signed in to change notification settings - Fork 24
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
Add checks for users, isolated logic -- refactored #7
Merged
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
Also add test case
Add option to only track authed sessions
We could rely on Django logout method (https://github.com/django/django/blob/master/django/contrib/auth/__init__.py) -- it would check user and flush session for us.
Reduce number of run-time operations in favor of init-time code. Use settings only for things could change in run-time.
refactor existing logic to eliminate bug where the middleware doesn't invalidate the cache if a remote address was not set on the request--even if the validate IP part is disabled.
Adds the ability to redirect to a known view, +tests and corrects the test runner to point at a real test url configuration.
Django 1.9 fails the Python 3.3.5 build because it requires 3.4 or later; it also fails the 2.6.x build because it requires at least 2.7 of the Python 2 series. This in the docs: https://docs.djangoproject.com/en/1.9/faq/install/#what-python-version-can-i-use-with-django
If the IP is known but then later is unknown, that also fails validation.
Update from master
refactored the support for RESTRICTEDSESSIONS_AUTHED_ONLY setting based on latest trunk.
For only restricting sessions when the users are logged in.
Thanks, merged. I'll try to roll a release soon! |
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 PR is intended as a replacement for the feature request of: #2
It rebases off the trunk and adds the feature in more minimally now that the refactor is less relevant.