Commit graph

14 commits

Author SHA1 Message Date
Pēteris Caune
6872ab3eb6
Improve type hints in hc.accounts.backends 2023-10-26 09:31:11 +03:00
Pēteris Caune
161430fb10
Sort imports and add "from __future__ import annotations" 2022-10-17 16:52:15 +03:00
Pēteris Caune
c1ff8875e3
Implement login link expiration
Login links will now expire in 1 hour.
2022-05-30 15:48:51 +03:00
Shea Polansky
54a95a0ee2
Add http header auth (#457)
* Add HTTP header authentiation backend/middleware

* Add docs for remote header auth

* Improve docs on external auth

* Add warning for unknown  REMOTE_USER_HEADER_TYPE

* Move active check for header auth to middleware
Add extra header type sanity check to the backend

* Add test cases for remote header login

* Improve header-based authentication

- remove the 'ID' mode
- add CustomHeaderBackend to AUTHENTICATION_BACKENDS conditionally
- rewrite CustomHeaderBackend and CustomHeaderMiddleware to
use less inherited code
- add more test cases

Co-authored-by: Pēteris Caune <cuu508@gmail.com>
2020-12-09 11:25:56 +02:00
Pēteris Caune
6a0c90853b
request.project is now unused, removing 2020-02-26 10:37:19 +02:00
Pēteris Caune
cdfc9840a7
Source formatted with Black 2019-05-15 14:27:50 +03:00
Pēteris Caune
d403260e9b
Preload Profile.current_project, saves one query per request. 2019-01-21 21:59:50 +02:00
Pēteris Caune
367f5a595d Small tweaks to make sure we don't query accounts_profile multiple times on every request. 2017-08-30 22:18:31 +03:00
Pēteris Caune
de7160a0e6 login, set-password, and change-email tokens use different salts. 2017-08-25 12:46:21 +03:00
Pēteris Caune
74f7c50a65 Fix deprecation warnings. 2017-06-02 22:39:53 +03:00
Pēteris Caune
a4bcbb28aa /admin/login/ uses the same login view as the main site. 2017-01-28 13:16:42 +02:00
Di Wu
79b7327c9e fix tests and optimize authentication and fix some unclosed markup 2016-01-04 23:47:32 -05:00
Pēteris Caune
1dacc8b797 Users can add passwords to their accounts. Fixes #6 2016-01-05 00:25:08 +02:00
Pēteris Caune
dd188064fa Store the one time login token in profile so user.password can be used for regular passwords. 2016-01-04 22:39:49 +02:00