1
0
mirror of https://github.com/oauth2-proxy/oauth2-proxy.git synced 2024-11-24 08:52:25 +02:00
oauth2-proxy/pkg
Jordan Crawford 6346dafc1e (#649) Remove blank helthcheck user agents and paths when setting up the healthcheck middleware
A blank user agent is considered == to an empty string. When no -ping-user-agent option is specified, this is considered to be an empty string.

This reveals two problems:
- When no ping-user-agent is specified, main.go sets up a health check user agent of ""
- When no user agent is specified, the empty string is still checked against the health check user agents.

Now the health check middleware ignores blank user agents and paths in order to sanitise it's input to avoid this issue.

Additional tests have been added to verify these situations.
2020-07-06 14:07:38 +12:00
..
apis Add Upstreams options struct with validation 2020-07-05 10:21:05 +01:00
cookies Rename CookieOptions to Cookie 2020-07-05 09:18:21 +01:00
encryption Move Encrypt/Decrypt Into helper to session_state.go 2020-06-12 14:46:35 -07:00
ip Move RealClientIP code to IP packages 2020-05-23 15:17:41 +01:00
logger Implements --real-client-ip-header option. (#503) 2020-05-12 18:41:25 +01:00
middleware (#649) Remove blank helthcheck user agents and paths when setting up the healthcheck middleware 2020-07-06 14:07:38 +12:00
requests Support context in providers (#519) 2020-05-10 13:34:59 +01:00
sessions Rename CookieOptions to Cookie 2020-07-05 09:18:21 +01:00
upstream Add tests for upstream package 2020-07-05 10:21:05 +01:00
util Fix #635: Support specifying alternative provider TLS trust source(s) (#645) 2020-07-03 16:09:17 +01:00
validation Add Upstreams options struct with validation 2020-07-05 10:21:05 +01:00