Skip to content

Commit f0ee26f

Browse files
author
Jakub Ječmínek
committed
Provide HttpRequest to the authenticate function
1 parent ca30e3f commit f0ee26f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

auth_token/contrib/common/forms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def password_auth_clean(self):
4949
username = self.cleaned_data.get(self.username_field_name)
5050
password = self.cleaned_data.get('password')
5151
if username and password:
52-
self.user_cache = authenticate(username=username, password=password)
52+
self.user_cache = authenticate(request=self.request, username=username, password=password)
5353
if self.user_cache is None:
5454
raise forms.ValidationError(
5555
self.error_messages['invalid_login'],

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
'tqdm>=4.62.3',
3535
],
3636
extras_require={
37-
'mssso': ['requests>=2.26.0', 'msal>=1.20.0', 'python3-saml>=1.16.0'],
37+
'mssso': ['requests>=2.26.0', 'msal>=1.20.0', 'python3-saml>=1.16.0', 'xmlsec==1.3.14'],
3838
},
3939
zip_safe=False
4040
)

0 commit comments

Comments
 (0)