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

Do not block webmail when we have a valid SSO session #3100

Merged
merged 1 commit into from
Dec 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/admin/mailu/internal/views/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def nginx_authentication():
is_valid_user = False
username = response.headers.get('Auth-User', None)
if response.headers.get("Auth-User-Exists") == "True":
if not is_app_token and utils.limiter.should_rate_limit_user(username, client_ip):
if not is_from_webmail and not is_app_token and utils.limiter.should_rate_limit_user(username, client_ip):
# FIXME could be done before handle_authentication()
status, code = nginx.get_status(flask.request.headers['Auth-Protocol'], 'ratelimit')
response = flask.Response()
Expand Down
1 change: 1 addition & 0 deletions towncrier/newsfragments/3094.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Ensure we do not block logins from webmails when there is a valid SSO session