pomerium/proxy
Cuong Manh Le 58fb6ea3c4
proxy: fix invalid session after logout in forward auth mode (#1062)
Currently, authorize service does handle unauthenticated request in
forward auth mode, and return status 401.

But proxy has not handled the response yet, and always returns 403 for
both unauthenticated and unauthorized request. That breaks session
handling in forward auth mode. That said, if user was signed out, or for
any reason, authorize service return 401 status, proxy does not redirect
user to re-signin, but always return 403.

To fix it, proxy is changed to handle envoy check response in more
details, to distinguish between 401 and 403 status.

Thanks to @simbaja for rasing the problem and come up with original fix.

Fixes #1014
Fixes #858
2020-07-14 01:07:49 +07:00
..
forward_auth.go proxy: fix invalid session after logout in forward auth mode (#1062) 2020-07-14 01:07:49 +07:00
forward_auth_test.go proxy: fix invalid session after logout in forward auth mode (#1062) 2020-07-14 01:07:49 +07:00
handlers.go cryptutil: move to pkg dir, add token generator (#1029) 2020-06-30 15:55:33 -06:00
handlers_test.go cryptutil: move to pkg dir, add token generator (#1029) 2020-06-30 15:55:33 -06:00
middleware.go proxy: fix invalid session after logout in forward auth mode (#1062) 2020-07-14 01:07:49 +07:00
middleware_test.go feature/databroker: user data and session refactor project (#926) 2020-06-19 07:52:44 -06:00
proxy.go cryptutil: move to pkg dir, add token generator (#1029) 2020-06-30 15:55:33 -06:00
proxy_test.go envoy: Initial changes 2020-05-18 17:10:10 -04:00