D. Berge
48e1369088
Fix host based authentication
2025-07-25 14:03:43 +02:00
D. Berge
3ea82cb660
Fix reading of credentials for issuing JWT
2025-07-24 23:03:05 +02:00
D. Berge
b3e27ed1b9
Refactor auth.authentify.
...
We now get the user's details directly from the JWT token.
2025-07-24 19:15:36 +02:00
D. Berge
addbe2d572
Refactor user authentication code to use database
2025-07-11 22:46:47 +02:00
D. Berge
141d5805ae
Reissue user login tokens when close to expiring
2020-10-23 14:50:35 +02:00
D. Berge
5594b6863c
Do not run authentication if headers already sent
2020-10-12 19:41:00 +02:00
D. Berge
947736e8c1
Check code rather than errno.
...
Different versions of that library work
differently.
2020-10-11 22:10:21 +02:00
D. Berge
cdd007ce88
Fix authentification middleware
2020-10-11 19:08:36 +02:00
D. Berge
2aca34e488
Read user login info from discrete file.
...
`$DOUGAL_ROOT/etc/users.yaml` to be exact.
2020-10-11 18:21:19 +02:00
D. Berge
a3bfb73937
Add authentication middleware.
...
The user is authenticated by one of the following
methods, in order of priority:
* The presence of a valid JWT.
* Its IP.
* Its hostname.
In the case of the latter two methods, if authentication
is successful a JWT valid for 15 minutes will be generated
and passed back to the user in a cookie.
2020-10-11 13:11:43 +02:00