mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-01-21 07:55:00 +00:00
sso: Add missing captcha/rate limiting on SSO login
Tests: - Install tt-rss. Logout. Visit the /tt-rss link. We will be redirected to the login page. Login with wrong password 3 times. CAPTCHA is shown. Login with correct password. Login will be successful. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
e89b0ee276
commit
08eb54ad0f
@ -3,6 +3,7 @@
|
||||
URLs for the Single Sign On module.
|
||||
"""
|
||||
|
||||
from axes.decorators import axes_dispatch
|
||||
from django.urls import re_path
|
||||
from stronghold.decorators import public
|
||||
|
||||
@ -11,8 +12,8 @@ from plinth.utils import non_admin_view
|
||||
from .views import SSOLoginView, refresh
|
||||
|
||||
urlpatterns = [
|
||||
re_path(r'^accounts/sso/login/$', public(SSOLoginView.as_view()),
|
||||
name='sso-login'),
|
||||
re_path(r'^accounts/sso/login/$',
|
||||
public(axes_dispatch(SSOLoginView.as_view())), name='sso-login'),
|
||||
re_path(r'^accounts/sso/refresh/$', non_admin_view(refresh),
|
||||
name='sso-refresh'),
|
||||
]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user