Trong Huu Nguyen
ea0756784d
refactor(handler/reverseproxy): use ReverseProxy.Rewrite instead of Director
2023-02-10 14:58:17 +01:00
Trong Huu Nguyen
473e4a95a7
refactor: remove loginstatus
...
Loginstatus is no longer needed with the SSO setup.
Fixes #50 .
2023-02-10 14:58:17 +01:00
Trong Huu Nguyen
c8f148d892
refactor(handler/error): remove custom redirect
...
Reduce the risk of exposing oauth query parameters in "dirty dancing" attacks.
2023-02-10 14:58:14 +01:00
Trong Huu Nguyen
42dcba8367
refactor: replace relative canonical redirect with handler
...
This also ensure that we clean any urls that may stem from user input (e.g.
url parameter or login cookie) before performing redirects.
2023-02-10 14:58:14 +01:00
Trong Huu Nguyen
c3c0c01926
feat(sso): partially implement handlers
2023-02-10 14:58:09 +01:00
Trong Huu Nguyen
9144056e28
refactor(handler): split up request handlers into separate modules
2022-09-02 14:53:11 +02:00
Trong Huu Nguyen
5ec969981d
fix(session/handler): ensure access token is not expired before proxying
2022-08-26 17:58:39 +02:00
Trong Huu Nguyen
d5bbca9897
feat: rudimentary support for refresh tokens
2022-08-26 14:32:39 +02:00
Trong Huu Nguyen
dc0741f79f
refactor(middleware): extract handlers for consistency
2022-08-26 08:34:07 +02:00
Trong Huu Nguyen
5990e4bb71
refactor(session): extract session handler
2022-08-19 11:44:13 +02:00
Trong Huu Nguyen
c15e00469b
refactor: clean up session error handling
2022-08-18 21:35:15 +02:00
Trong Huu Nguyen
ae8028cc96
refactor: remove cookie session fallback store
...
The implementation is error-prone and difficult to maintain.
We instead just assume that the backing session store is highly
available.
2022-08-17 20:44:07 +02:00
Trong Huu Nguyen
5a50ba7c3a
feat: support multiple ingresses
...
Replace hardcoded callback URLs with dynamic generation
of URLs based on incoming requests. These are validated against
a pre-registered list of ingresses for which Wonderwall is considered
authorative for.
We also preserve the cookie behaviour; the most specific ingress path
and domain is used for the cookies.
The `url` package has been moved to the `handler` package, and its
implementation refactored slightly for readability and DRY.
2022-08-17 20:43:56 +02:00
Trong Huu Nguyen
a9e9644764
refactor: move context utils to middleware
2022-08-17 11:39:40 +02:00
Trong Huu Nguyen
cbc49de826
refactor(handler/default): clean up access token getter
2022-08-11 09:31:27 +02:00
Trong Huu Nguyen
13fd194318
refactor(handler/default): extract reverseproxy to avoid unnecessary instantiation
2022-08-11 09:31:10 +02:00
Trong Huu Nguyen
4646c36b74
refactor(autologin): skip -> ignore
2022-07-21 12:50:55 +02:00
Trong Huu Nguyen
31ab8ad3b7
refactor(handler/default): redirect auto-login requests instead of inlining login handler
2022-07-21 08:21:28 +02:00
Trong Huu Nguyen
27ea0793ba
refactor(handler): reduce logging severity for spammy statements
2022-07-21 07:49:58 +02:00
Trong Huu Nguyen
595d902dcd
fix(handler/default): only assert loginstatus if we already have an active session
2022-07-20 15:56:23 +02:00
Trong Huu Nguyen
eac2d5789d
refactor: passthrough for consistency in openid configuration
2022-07-20 09:58:49 +02:00
Trong Huu Nguyen
09ab8b9e3b
refactor(handler): minor cleanups
2022-07-19 20:11:52 +02:00
Trong Huu Nguyen
4ab07e9dc2
refactor: clean up logging
2022-07-19 08:39:02 +02:00
Trong Huu Nguyen
81fa96ccb8
refactor(handler/default): minor cleanups for loginstatus
2022-07-19 08:38:52 +02:00
Trong Huu Nguyen
bece03c94e
refactor(middleware/logentry): replace zerologger with logrus
2022-07-18 15:47:35 +02:00
Trong Huu Nguyen
ef649e7aaa
feat: add allowlisting of paths for autologin
2022-07-17 20:11:55 +02:00
Trong Huu Nguyen
e3b9d33296
refactor: split out packages from router
2022-07-15 07:44:54 +02:00