Commit Graph

17 Commits

Author SHA1 Message Date
max
6d6aff50b3 Only show logout (now CSRF protected) if user is authenticated, include relevant authentication logic in GET controllers (this should be moved to middleware) 2024-02-14 13:20:35 -06:00
max
dc450e26dd Move logout to POST route and controller with CSRF middleware. Add CsrfToken to home for logout 2024-02-12 14:46:26 -06:00
Maximilian
b30af86e58 Prebuild templates (base.html + content) at startup to avoid a file parse every page load 2023-12-22 21:03:15 -06:00
Maximilian
ed712a5344 Clean up error handling, migrate to log/slog, add todo for flash message system in post controller 2023-09-03 15:45:12 -05:00
Maximilian
9670b7d717 Better naming of functions and files, delete less than helpful comments 2023-08-03 12:09:40 -05:00
Maximilian
bada24884a Use ungrouped CSRF middleware on register and login POST routes 2023-07-21 11:59:55 -05:00
max
5f7e674d32 Add remember me functionality, handle both types of sessions appropriately 2023-04-06 08:56:48 -05:00
Maximilian
9e4216301d Move models to its own package 2023-02-08 19:39:53 -06:00
Maximilian
8c93b3746b Fix csrf token unexported error 2022-12-04 19:06:51 -06:00
Maximilian
e8e42f3724 Code cleanup 2022-12-04 18:04:24 -06:00
max
1eb278c4b9 Use csrf tokens and validation with login and register forms 2022-11-14 12:29:55 -06:00
Maximilian
a6b6c259ce Proper Logout logic 2022-11-01 17:29:41 -05:00
Maximilian
601b3d2cb0 Login function now authenticates and redirects 2022-11-01 16:14:49 -05:00
max
187d10ca4a Routes and show controller functions for login and logout 2022-11-01 11:23:44 -05:00
max
5a9ee796f8 Rearrange functions 2022-11-01 11:23:08 -05:00
Maximilian
a590c96d0b Error handling for CreateUser query 2022-10-22 12:18:14 -05:00
max
e73c006550 Routing, templating, and database handling 2022-10-20 11:59:33 -05:00