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

Bump django-axes to v7.0.1 #1103

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Bump django-axes to v7.0.1 #1103

wants to merge 3 commits into from

Conversation

gounux
Copy link
Contributor

@gounux gounux commented Jan 8, 2025

@duke-nyuki
Copy link
Collaborator

Task linked: QF-4848 Bump django-axes to 6.0.0+

@gounux gounux marked this pull request as ready for review January 9, 2025 08:09
@gounux gounux requested a review from suricactus January 9, 2025 08:09
Comment on lines +375 to +376
# Configures the limiter to handle username only (see https://django-axes.readthedocs.io/en/latest/2_installation.html#version-7-breaking-changes-and-upgrading-from-django-axes-version-6)
AXES_LOCKOUT_PARAMETERS = ["username"]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a bit of space to improve readability.

Suggested change
# Configures the limiter to handle username only (see https://django-axes.readthedocs.io/en/latest/2_installation.html#version-7-breaking-changes-and-upgrading-from-django-axes-version-6)
AXES_LOCKOUT_PARAMETERS = ["username"]
# Configures the limiter to handle username only.
# See https://django-axes.readthedocs.io/en/latest/2_installation.html#version-7-breaking-changes-and-upgrading-from-django-axes-version-6
AXES_LOCKOUT_PARAMETERS = ["username"]

Why don't we ratelimit on email login too?

Copy link
Contributor Author

@gounux gounux Jan 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting : axes rate limiter's lockout allowed parameters seem to be only username, ip and useragent

I get this error when trying to add somehow email to the AXES_LOCKOUT_PARAMETERS :

'email' lockout parameter is not allowed. Allowed parameters: username, ip_address, user_agent

This comment looks interesting : I tried setting the AXES_USERNAME_FORM_FIELD = "email"

-> the rate limiter works fine with email :

image

But, axes rate limiter then doesn't work with username, and it looks like allauth's rate limiter is then activated :

image

Would it mean that axes's rate limiter works only with username OR email, and not both of them simultaneously ?

@gounux gounux mentioned this pull request Jan 12, 2025
4 tasks
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

Successfully merging this pull request may close these issues.

3 participants