git.iko.soy/typeable/oauth2-proxy
on master help sign in
614 files changed+44343−20593
since splitsnapshots
unifiedsplit
.devcontainer/Dockerfile+1−1 .github/FUNDING.yml+15 .github/ISSUE_TEMPLATE/bug-report.yml+1 .github/ISSUE_TEMPLATE/config.yml+2−2 .github/ISSUE_TEMPLATE/configuration-support.yml+1 .github/ISSUE_TEMPLATE/feature-request.yml+1 .github/PULL_REQUEST_TEMPLATE.md+3−2 .github/renovate.json5+9 .github/workflows/ci.yaml−75 .github/workflows/ci.yml+118 .github/workflows/codeql.yml+18−15 .github/workflows/create-release.yml+5−3 .github/workflows/docs.yaml → .github/workflows/docs.yml+11−13 .github/workflows/e2e.yml+14 .github/workflows/labeler.yaml → .github/workflows/labeler.yml+1−1 .github/workflows/nightly.yml+6−6 .github/workflows/publish-release.yml+24−23 .github/workflows/stale.yml+7−3 .github/workflows/test.sh−26 .gitignore+1 .golangci.yml+69−38 CHANGELOG.md+585 CODE_OF_CONDUCT.md+81−103 DCO.md+34 Dockerfile+30−7 MAINTAINERS+2−4 MAINTAINERS.md+33 Makefile+106−58 README.md+74−47 RELEASE.md+2−2 contrib/local-environment/Makefile+2−2 contrib/local-environment/dex-traefik.yaml+25 contrib/local-environment/dex.yaml+16−20 contrib/local-environment/docker-compose-alpha-config.yaml+37−2 contrib/local-environment/docker-compose-gitea.yaml+4−7 contrib/local-environment/docker-compose-keycloak.yaml+12−20 contrib/local-environment/docker-compose-nginx.yaml+39−15 contrib/local-environment/docker-compose-traefik.yaml+42−17 contrib/local-environment/docker-compose.yaml+7−23 contrib/local-environment/keycloak/master-realm.json → contrib/local-environment/keycloak/oauth2-proxy-realm.json+18−18 contrib/local-environment/keycloak/master-users-0.json → contrib/local-environment/keycloak/oauth2-proxy-users-0.json+1−1 contrib/local-environment/kubernetes/Chart.lock+4−4 contrib/local-environment/kubernetes/Chart.yaml+2−2 contrib/local-environment/kubernetes/README.md+1 contrib/local-environment/kubernetes/values.yaml+11−5 contrib/local-environment/nginx.conf+31−73 contrib/local-environment/oauth2-proxy-alpha-config.cfg+1−2 contrib/local-environment/oauth2-proxy-alpha-config.yaml+21−21 contrib/local-environment/oauth2-proxy-keycloak.cfg+4−4 contrib/local-environment/oauth2-proxy-nginx.cfg+11−6 contrib/local-environment/oauth2-proxy-traefik.cfg+5−5 contrib/local-environment/oauth2-proxy.cfg+2−2 contrib/local-environment/traefik/dynamic.yaml+11−4 contrib/local-environment/traefik/traefik.yaml+2 contrib/oauth2-proxy.service.example+25−14 dist.sh+11−3 docs/.gitignore+3 docs/README.md+1−1 docs/docs/behaviour.md+20−5 docs/docs/community/contribution.md+23−10 docs/docs/community/security.md+1−1 docs/docs/configuration/alpha_config.md+198−31 docs/docs/configuration/alpha_config.md.tmpl+159−6 docs/docs/configuration/integrations/caddy.md+63 docs/docs/configuration/integrations/headlamp.md+105 docs/docs/configuration/integrations/index.md+41 docs/docs/configuration/integrations/kubernetes-dashboard.md+289 docs/docs/configuration/integrations/nginx.md+190 docs/docs/configuration/integrations/traefik.md+192 docs/docs/configuration/overview.md+330−487 docs/docs/configuration/providers/atlassian.md+26 docs/docs/configuration/providers/azure_ad.md−9 docs/docs/configuration/providers/cidaas.md+37 docs/docs/configuration/providers/cisco_duo.md+44 docs/docs/configuration/providers/dtt_sso.md+45 docs/docs/configuration/providers/gitea.md+5−1 docs/docs/configuration/providers/github.md+35−9 docs/docs/configuration/providers/gitlab.md+10−1 docs/docs/configuration/providers/google.md+25−4 docs/docs/configuration/providers/index.md+15−9 docs/docs/configuration/providers/keycloak.md+2−2 docs/docs/configuration/providers/keycloak_oidc.md+8 docs/docs/configuration/providers/ms_azure_ad.md+59 docs/docs/configuration/providers/ms_entra_id.md+201 docs/docs/configuration/providers/sourcehut.md+25 docs/docs/configuration/sessions.md+6−4 docs/docs/configuration/systemd_socket.md+51 docs/docs/features/endpoints.md+27−1 docs/docs/installation.md+3−2 docs/docs/welcome.md+11−1 docs/docusaurus.config.js+3−3 docs/package-lock.json−15901 docs/package.json+4−1 docs/sidebars.js+36−16 docs/src/css/custom.css+14 docs/static/img/architecture.svg−1 docs/static/img/simplified-architecture.svg+4 docs/versioned_docs/version-7.0.x/behaviour.md+1−1 docs/versioned_docs/version-7.0.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.1.x/behaviour.md+1−1 docs/versioned_docs/version-7.1.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.10.x/behaviour.md+26 docs/versioned_docs/version-7.10.x/community/contribution.md+89 docs/versioned_docs/version-7.10.x/community/security.md+49 docs/versioned_docs/version-7.10.x/configuration/alpha_config.md+564 docs/versioned_docs/version-7.10.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.10.x/configuration/integration.md+386 docs/versioned_docs/version-7.10.x/configuration/overview.md+403 docs/versioned_docs/version-7.10.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.10.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.10.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.10.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.10.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.10.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.10.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.10.x/configuration/providers/google.md+76 docs/versioned_docs/version-7.10.x/configuration/providers/index.md+43 docs/versioned_docs/version-7.10.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.10.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.10.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.10.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.10.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.10.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.10.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.10.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.10.x/configuration/sessions.md+99 docs/versioned_docs/version-7.10.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.10.x/configuration/tls.md+85 docs/versioned_docs/version-7.10.x/features/endpoints.md+47 docs/versioned_docs/version-7.10.x/installation.md+32 docs/versioned_docs/version-7.10.x/welcome.md+23 docs/versioned_docs/version-7.11.x/behaviour.md+26 docs/versioned_docs/version-7.11.x/community/contribution.md+89 docs/versioned_docs/version-7.11.x/community/security.md+49 docs/versioned_docs/version-7.11.x/configuration/alpha_config.md+564 docs/versioned_docs/version-7.11.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.11.x/configuration/integration.md+386 docs/versioned_docs/version-7.11.x/configuration/overview.md+406 docs/versioned_docs/version-7.11.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.11.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.11.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.11.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.11.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.11.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.11.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.11.x/configuration/providers/google.md+75 docs/versioned_docs/version-7.11.x/configuration/providers/index.md+44 docs/versioned_docs/version-7.11.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.11.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.11.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.11.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.11.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.11.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.11.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.11.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.11.x/configuration/providers/sourcehut.md+25 docs/versioned_docs/version-7.11.x/configuration/sessions.md+99 docs/versioned_docs/version-7.11.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.11.x/configuration/tls.md+85 docs/versioned_docs/version-7.11.x/features/endpoints.md+47 docs/versioned_docs/version-7.11.x/installation.md+32 docs/versioned_docs/version-7.11.x/welcome.md+23 docs/versioned_docs/version-7.12.x/behaviour.md+26 docs/versioned_docs/version-7.12.x/community/contribution.md+89 docs/versioned_docs/version-7.12.x/community/security.md+49 docs/versioned_docs/version-7.12.x/configuration/alpha_config.md+565 docs/versioned_docs/version-7.12.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.12.x/configuration/integration.md+386 docs/versioned_docs/version-7.12.x/configuration/overview.md+407 docs/versioned_docs/version-7.12.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.12.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.12.x/configuration/providers/cidaas.md+37 docs/versioned_docs/version-7.12.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.12.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.12.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.12.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.12.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.12.x/configuration/providers/google.md+75 docs/versioned_docs/version-7.12.x/configuration/providers/index.md+45 docs/versioned_docs/version-7.12.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.12.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.12.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.12.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.12.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.12.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.12.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.12.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.12.x/configuration/providers/sourcehut.md+25 docs/versioned_docs/version-7.12.x/configuration/sessions.md+99 docs/versioned_docs/version-7.12.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.12.x/configuration/tls.md+85 docs/versioned_docs/version-7.12.x/features/endpoints.md+47 docs/versioned_docs/version-7.12.x/installation.md+32 docs/versioned_docs/version-7.12.x/welcome.md+23 docs/versioned_docs/version-7.13.x/behaviour.md+26 docs/versioned_docs/version-7.13.x/community/contribution.md+91 docs/versioned_docs/version-7.13.x/community/security.md+49 docs/versioned_docs/version-7.13.x/configuration/alpha_config.md+568 docs/versioned_docs/version-7.13.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.13.x/configuration/integrations/caddy.md+63 docs/versioned_docs/version-7.13.x/configuration/integrations/headlamp.md+105 docs/versioned_docs/version-7.13.x/configuration/integrations/index.md+41 docs/versioned_docs/version-7.13.x/configuration/integrations/kubernetes-dashboard.md+289 docs/versioned_docs/version-7.13.x/configuration/integrations/nginx.md+174 docs/versioned_docs/version-7.13.x/configuration/integrations/traefik.md+192 docs/versioned_docs/version-7.13.x/configuration/overview.md+407 docs/versioned_docs/version-7.13.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.13.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.13.x/configuration/providers/cidaas.md+37 docs/versioned_docs/version-7.13.x/configuration/providers/cisco_duo.md+44 docs/versioned_docs/version-7.13.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.13.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.13.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.13.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.13.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.13.x/configuration/providers/google.md+84 docs/versioned_docs/version-7.13.x/configuration/providers/index.md+46 docs/versioned_docs/version-7.13.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.13.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.13.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.13.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.13.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.13.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.13.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.13.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.13.x/configuration/providers/sourcehut.md+25 docs/versioned_docs/version-7.13.x/configuration/sessions.md+99 docs/versioned_docs/version-7.13.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.13.x/configuration/tls.md+85 docs/versioned_docs/version-7.13.x/features/endpoints.md+47 docs/versioned_docs/version-7.13.x/installation.md+32 docs/versioned_docs/version-7.13.x/welcome.md+23 docs/versioned_docs/version-7.14.x/behaviour.md+26 docs/versioned_docs/version-7.14.x/community/contribution.md+91 docs/versioned_docs/version-7.14.x/community/security.md+49 docs/versioned_docs/version-7.14.x/configuration/alpha_config.md+637 docs/versioned_docs/version-7.14.x/configuration/alpha_config.md.tmpl+218 docs/versioned_docs/version-7.14.x/configuration/integrations/caddy.md+63 docs/versioned_docs/version-7.14.x/configuration/integrations/headlamp.md+105 docs/versioned_docs/version-7.14.x/configuration/integrations/index.md+41 docs/versioned_docs/version-7.14.x/configuration/integrations/kubernetes-dashboard.md+289 docs/versioned_docs/version-7.14.x/configuration/integrations/nginx.md+174 docs/versioned_docs/version-7.14.x/configuration/integrations/traefik.md+192 docs/versioned_docs/version-7.14.x/configuration/overview.md+407 docs/versioned_docs/version-7.14.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.14.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.14.x/configuration/providers/cidaas.md+37 docs/versioned_docs/version-7.14.x/configuration/providers/cisco_duo.md+44 docs/versioned_docs/version-7.14.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.14.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.14.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.14.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.14.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.14.x/configuration/providers/google.md+84 docs/versioned_docs/version-7.14.x/configuration/providers/index.md+46 docs/versioned_docs/version-7.14.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.14.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.14.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.14.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.14.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.14.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.14.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.14.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.14.x/configuration/providers/sourcehut.md+25 docs/versioned_docs/version-7.14.x/configuration/sessions.md+99 docs/versioned_docs/version-7.14.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.14.x/configuration/tls.md+85 docs/versioned_docs/version-7.14.x/features/endpoints.md+59 docs/versioned_docs/version-7.14.x/installation.md+32 docs/versioned_docs/version-7.14.x/welcome.md+32 docs/versioned_docs/version-7.15.x/behaviour.md+26 docs/versioned_docs/version-7.15.x/community/contribution.md+91 docs/versioned_docs/version-7.15.x/community/security.md+49 docs/versioned_docs/version-7.15.x/configuration/alpha_config.md+702 docs/versioned_docs/version-7.15.x/configuration/alpha_config.md.tmpl+281 docs/versioned_docs/version-7.15.x/configuration/integrations/caddy.md+63 docs/versioned_docs/version-7.15.x/configuration/integrations/headlamp.md+105 docs/versioned_docs/version-7.15.x/configuration/integrations/index.md+41 docs/versioned_docs/version-7.15.x/configuration/integrations/kubernetes-dashboard.md+289 docs/versioned_docs/version-7.15.x/configuration/integrations/nginx.md+174 docs/versioned_docs/version-7.15.x/configuration/integrations/traefik.md+192 docs/versioned_docs/version-7.15.x/configuration/overview.md+451 docs/versioned_docs/version-7.15.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.15.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.15.x/configuration/providers/cidaas.md+37 docs/versioned_docs/version-7.15.x/configuration/providers/cisco_duo.md+44 docs/versioned_docs/version-7.15.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.15.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.15.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.15.x/configuration/providers/github.md+81 docs/versioned_docs/version-7.15.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.15.x/configuration/providers/google.md+84 docs/versioned_docs/version-7.15.x/configuration/providers/index.md+46 docs/versioned_docs/version-7.15.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.15.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.15.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.15.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.15.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.15.x/configuration/providers/ms_entra_id.md+201 docs/versioned_docs/version-7.15.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.15.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.15.x/configuration/providers/sourcehut.md+25 docs/versioned_docs/version-7.15.x/configuration/sessions.md+99 docs/versioned_docs/version-7.15.x/configuration/systemd_socket.md+51 docs/versioned_docs/version-7.15.x/configuration/tls.md+85 docs/versioned_docs/version-7.15.x/features/endpoints.md+73 docs/versioned_docs/version-7.15.x/installation.md+32 docs/versioned_docs/version-7.15.x/welcome.md+33 docs/versioned_docs/version-7.2.x/behaviour.md+20−5 docs/versioned_docs/version-7.2.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.3.x/behaviour.md+20−5 docs/versioned_docs/version-7.3.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.4.x/behaviour.md+20−5 docs/versioned_docs/version-7.4.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.5.x/behaviour.md+20−5 docs/versioned_docs/version-7.5.x/configuration/overview.md+2−2 docs/versioned_docs/version-7.6.x/behaviour.md+20−5 docs/versioned_docs/version-7.6.x/configuration/integration.md+318 docs/versioned_docs/version-7.6.x/configuration/overview.md+247−464 docs/versioned_docs/version-7.6.x/configuration/providers/github.md+12 docs/versioned_docs/version-7.6.x/configuration/providers/gitlab.md+10−1 docs/versioned_docs/version-7.6.x/configuration/providers/google.md+14−1 docs/versioned_docs/version-7.6.x/configuration/providers/keycloak_oidc.md+8 docs/versioned_docs/version-7.6.x/features/endpoints.md+1−1 docs/versioned_docs/version-7.6.x/welcome.md+1−1 docs/versioned_docs/version-7.7.x/behaviour.md+26 docs/versioned_docs/version-7.7.x/community/contribution.md+78 docs/versioned_docs/version-7.7.x/community/security.md+49 docs/versioned_docs/version-7.7.x/configuration/alpha_config.md+546 docs/versioned_docs/version-7.7.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.7.x/configuration/integration.md+318 docs/versioned_docs/version-7.7.x/configuration/overview.md+396 docs/versioned_docs/version-7.7.x/configuration/providers/adfs.md+19 docs/docs/configuration/providers/azure.md → docs/versioned_docs/version-7.7.x/configuration/providers/azure.md+9 docs/versioned_docs/version-7.7.x/configuration/providers/azure_ad.md+18 docs/versioned_docs/version-7.7.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.7.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.7.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.7.x/configuration/providers/gitea.md+20 docs/versioned_docs/version-7.7.x/configuration/providers/github.md+67 docs/versioned_docs/version-7.7.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.7.x/configuration/providers/google.md+76 docs/versioned_docs/version-7.7.x/configuration/providers/index.md+42 docs/versioned_docs/version-7.7.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.7.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.7.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.7.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.7.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.7.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.7.x/configuration/sessions.md+99 docs/versioned_docs/version-7.7.x/configuration/tls.md+85 docs/versioned_docs/version-7.7.x/features/endpoints.md+47 docs/versioned_docs/version-7.7.x/installation.md+31 docs/versioned_docs/version-7.7.x/welcome.md+23 docs/versioned_docs/version-7.8.x/behaviour.md+26 docs/versioned_docs/version-7.8.x/community/contribution.md+89 docs/versioned_docs/version-7.8.x/community/security.md+49 docs/versioned_docs/version-7.8.x/configuration/alpha_config.md+563 docs/versioned_docs/version-7.8.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.8.x/configuration/integration.md+318 docs/versioned_docs/version-7.8.x/configuration/overview.md+401 docs/versioned_docs/version-7.8.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.8.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.8.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.8.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.8.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.8.x/configuration/providers/github.md+67 docs/versioned_docs/version-7.8.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.8.x/configuration/providers/google.md+76 docs/versioned_docs/version-7.8.x/configuration/providers/index.md+43 docs/versioned_docs/version-7.8.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.8.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.8.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.8.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.8.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.8.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.8.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.8.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.8.x/configuration/sessions.md+99 docs/versioned_docs/version-7.8.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.8.x/configuration/tls.md+85 docs/versioned_docs/version-7.8.x/features/endpoints.md+47 docs/versioned_docs/version-7.8.x/installation.md+32 docs/versioned_docs/version-7.8.x/welcome.md+23 docs/versioned_docs/version-7.9.x/behaviour.md+26 docs/versioned_docs/version-7.9.x/community/contribution.md+89 docs/versioned_docs/version-7.9.x/community/security.md+49 docs/versioned_docs/version-7.9.x/configuration/alpha_config.md+564 docs/versioned_docs/version-7.9.x/configuration/alpha_config.md.tmpl+139 docs/versioned_docs/version-7.9.x/configuration/integration.md+318 docs/versioned_docs/version-7.9.x/configuration/overview.md+403 docs/versioned_docs/version-7.9.x/configuration/providers/adfs.md+19 docs/versioned_docs/version-7.9.x/configuration/providers/bitbucket.md+25 docs/versioned_docs/version-7.9.x/configuration/providers/digitalocean.md+21 docs/versioned_docs/version-7.9.x/configuration/providers/facebook.md+7 docs/versioned_docs/version-7.9.x/configuration/providers/gitea.md+24 docs/versioned_docs/version-7.9.x/configuration/providers/github.md+67 docs/versioned_docs/version-7.9.x/configuration/providers/gitlab.md+49 docs/versioned_docs/version-7.9.x/configuration/providers/google.md+76 docs/versioned_docs/version-7.9.x/configuration/providers/index.md+43 docs/versioned_docs/version-7.9.x/configuration/providers/keycloak.md+36 docs/versioned_docs/version-7.9.x/configuration/providers/keycloak_oidc.md+151 docs/versioned_docs/version-7.9.x/configuration/providers/linkedin.md+13 docs/versioned_docs/version-7.9.x/configuration/providers/login_gov.md+79 docs/versioned_docs/version-7.9.x/configuration/providers/ms_azure_ad.md+59 docs/versioned_docs/version-7.9.x/configuration/providers/ms_entra_id.md+197 docs/versioned_docs/version-7.9.x/configuration/providers/nextcloud.md+28 docs/versioned_docs/version-7.9.x/configuration/providers/openid_connect.md+146 docs/versioned_docs/version-7.9.x/configuration/sessions.md+99 docs/versioned_docs/version-7.9.x/configuration/systemd_socket.md+43 docs/versioned_docs/version-7.9.x/configuration/tls.md+85 docs/versioned_docs/version-7.9.x/features/endpoints.md+47 docs/versioned_docs/version-7.9.x/installation.md+32 docs/versioned_docs/version-7.9.x/welcome.md+23 docs/versioned_sidebars/version-7.10.x-sidebars.json+83 docs/versioned_sidebars/version-7.11.x-sidebars.json+84 docs/versioned_sidebars/version-7.12.x-sidebars.json+84 docs/versioned_sidebars/version-7.13.x-sidebars.json+100 docs/versioned_sidebars/version-7.14.x-sidebars.json+100 docs/versioned_sidebars/version-7.15.x-sidebars.json+100 docs/versioned_sidebars/version-7.6.x-sidebars.json+1 docs/versioned_sidebars/version-7.7.x-sidebars.json+83 docs/versioned_sidebars/version-7.8.x-sidebars.json+83 docs/versioned_sidebars/version-7.9.x-sidebars.json+83 docs/versions.json+9 go.mod+61−75 go.sum+166−306 main.go+45−14 main_suite_test.go+1−1 main_test.go+162−56 oauthproxy.go+113−43 oauthproxy_test.go+423−79 pkg/apis/middleware/middleware_suite_test.go+1−1 pkg/apis/middleware/scope.go+48−1 pkg/apis/middleware/scope_test.go+35−1 pkg/apis/middleware/session.go+5−1 pkg/apis/options/alpha_options.go+25−16 pkg/apis/options/common.go−63 pkg/apis/options/common_test.go−88 pkg/apis/options/cookie.go+49−22 pkg/apis/options/cookie_test.go+70 pkg/apis/options/doc.go+2−1 pkg/apis/options/header.go+54−9 pkg/apis/options/hooks.go+57 pkg/apis/options/hooks_test.go+96 pkg/apis/options/legacy_options.go+90−45 pkg/apis/options/legacy_options_test.go+124−77 pkg/apis/options/load.go+92−36 pkg/apis/options/load_test.go+50−23 pkg/apis/options/login_url_parameters.go+5−5 pkg/apis/options/options.go+48−23 pkg/apis/options/options_suite_test.go+1−1 pkg/apis/options/providers.go+233−67 pkg/apis/options/secret_source.go+19 pkg/apis/options/server.go+16−7 pkg/apis/options/testutil/options_matcher_test.go+1−1 pkg/apis/options/upstreams.go+110−23 pkg/apis/options/util/util_suite_test.go+1−1 pkg/apis/options/util/util_test.go+1−1 pkg/apis/sessions/session_state.go+30−7 pkg/apis/sessions/session_state_test.go+105−15 pkg/app/pagewriter/error_page_test.go+1−1 pkg/app/pagewriter/pagewriter_suite_test.go+1−1 pkg/app/pagewriter/pagewriter_test.go+4−5 pkg/app/pagewriter/sign_in_page_test.go+1−2 pkg/app/pagewriter/static_pages_test.go+1−1 pkg/app/pagewriter/templates_test.go+1−1 pkg/app/redirect/director_test.go+45−14 pkg/app/redirect/pagewriter_suite_test.go+1−1 pkg/app/redirect/validator_test.go+1−2 pkg/authentication/basic/basic_suite_test.go+1−1 pkg/authentication/basic/htpasswd.go+1−1 pkg/authentication/basic/htpasswd_test.go+12−10 pkg/authentication/hmacauth/LICENSE.md+5 pkg/authentication/hmacauth/hmacauth.go+237 pkg/authentication/hmacauth/hmacauth_test.go+302 pkg/clock/clock.go−157 pkg/clock/clock_suite_test.go−17 pkg/clock/clock_test.go−380 pkg/cookies/cookies.go+19−7 pkg/cookies/cookies_suite_test.go+5−8 pkg/cookies/cookies_test.go+49−43 pkg/cookies/csrf.go+123−43 pkg/cookies/csrf_per_request_test.go+90−7 pkg/cookies/csrf_test.go+354−9 pkg/encryption/cipher.go+2−2 pkg/encryption/nonce.go+8−9 pkg/encryption/utils.go+7−11 pkg/encryption/utils_test.go+4−4 pkg/header/header_suite_test.go+1−1 pkg/header/injector_test.go+1−2 pkg/ip/parse_ip_net.go+16 pkg/ip/parse_ip_net_test.go+118 pkg/ip/realclientip.go+13−2 pkg/ip/realclientip_test.go+6 pkg/middleware/basic_session_test.go+1−2 pkg/middleware/headers.go+40−5 pkg/middleware/headers_test.go+50−6 pkg/middleware/healthcheck.go+7−4 pkg/middleware/healthcheck_test.go+32−11 pkg/middleware/jwt_session.go+14−7 pkg/middleware/jwt_session_test.go+89−5 pkg/middleware/metrics_test.go+1−2 pkg/middleware/middleware_suite_test.go+1−1 pkg/middleware/readynesscheck_test.go+1−2 pkg/middleware/redirect_to_https_test.go+16−2 pkg/middleware/request_logger_test.go+1−2 pkg/middleware/scope.go+5−3 pkg/middleware/scope_test.go+19−5 pkg/middleware/session_utils_test.go+1−2 pkg/middleware/stored_session.go+47−3 pkg/middleware/stored_session_test.go+67−12 pkg/providers/oidc/oidc_suite_test.go+1−1 pkg/providers/oidc/provider_test.go+1−2 pkg/providers/oidc/provider_verifier.go+116−11 pkg/providers/oidc/provider_verifier_test.go+156−4 pkg/providers/oidc/verifier_test.go+1−1 pkg/providers/util/claim_extractor.go+31−82 pkg/providers/util/claim_extractor_test.go+65−51 pkg/providers/util/util_suite_test.go+1−1 pkg/http/http_suite_test.go → pkg/proxyhttp/http_suite_test.go+2−2 pkg/http/server.go → pkg/proxyhttp/server.go+76−5 pkg/http/server_group.go → pkg/proxyhttp/server_group.go+1−1 pkg/http/server_group_test.go → pkg/proxyhttp/server_group_test.go+2−2 pkg/http/server_test.go → pkg/proxyhttp/server_test.go+373−4 pkg/proxyhttp/systemd_socket.go+55 pkg/proxyhttp/systemd_unsupported.go+17 pkg/requests/builder_test.go+16−16 pkg/requests/http.go+3−1 pkg/requests/requests_suite_test.go+1−1 pkg/requests/result_test.go+3−4 pkg/requests/util/util.go+45−11 pkg/requests/util/util_suite_test.go+1−1 pkg/requests/util/util_test.go+120−23 pkg/sessions/cookie/session_store.go+41−22 pkg/sessions/cookie/session_store_test.go+1−1 pkg/sessions/persistence/manager_test.go+1−1 pkg/sessions/persistence/persistence_suite_test.go+1−1 pkg/sessions/persistence/ticket.go+36−20 pkg/sessions/persistence/ticket_test.go+1−2 pkg/sessions/redis/client_test.go+1−1 pkg/sessions/redis/redis_store.go+23−9 pkg/sessions/redis/redis_store_test.go+177−323 pkg/sessions/redis/redis_store_tls_test.go+169 pkg/sessions/redis/redis_test.go+35−2 pkg/sessions/session_store_test.go+1−1 pkg/sessions/tests/session_store_tests.go+49−2 pkg/upstream/file.go+39−5 pkg/upstream/file_test.go+8−3 pkg/upstream/http.go+79−26 pkg/upstream/http_test.go+142−35 pkg/upstream/proxy.go+19−18 pkg/upstream/proxy_test.go+60−11 pkg/upstream/rewrite.go+1 pkg/upstream/rewrite_test.go+9−2 pkg/upstream/static.go+3−11 pkg/upstream/static_test.go+1−2 pkg/upstream/upstream_suite_test.go+4−2 pkg/util/ptr/ptr.go+14 pkg/util/ptr/ptr_test.go+38 pkg/util/util.go+64 pkg/util/util_test.go+70 pkg/validation/allowlist.go+14−1 pkg/validation/allowlist_test.go+31−2 pkg/validation/common_test.go+1−2 pkg/validation/cookie.go+23−4 pkg/validation/cookie_test.go+48−1 pkg/validation/header.go+1 pkg/validation/header_test.go+1−2 pkg/validation/options.go+7−9 pkg/validation/options_test.go+25−4 pkg/validation/providers.go+95−17 pkg/validation/providers_test.go+54−2 pkg/validation/sessions_test.go+6−5 pkg/validation/upstreams.go+10−8 pkg/validation/upstreams_test.go+27−10 pkg/validation/validation_suite_test.go+1−1 providers/adfs.go+2−1 providers/adfs_test.go+3−3 providers/atlassian-cloud.go+99 providers/atlassian-cloud_test.go+93 providers/azure.go+4−4 providers/cidaas.go+144 providers/cidaas_test.go+493 providers/dtt_sso.go+202 providers/dtt_sso_test.go+237 providers/github.go+75−21 providers/github_test.go+129 providers/gitlab_test.go+1−2 providers/google.go+207−40 providers/google_test.go+129−12 providers/internal_util.go+2−1 providers/internal_util_test.go+6 providers/keycloak_oidc.go+20−12 providers/keycloak_oidc_test.go+31−18 providers/keycloak_test.go+1−2 providers/logingov.go+4−3 providers/ms_entra_id.go+326 providers/ms_entra_id_test.go+186 providers/oidc.go+29−10 providers/oidc_test.go+30−1 providers/provider_data.go+46−5 providers/provider_data_test.go+23 providers/provider_default.go+8−1 providers/provider_default_test.go+42−2 providers/providers.go+28−11 providers/providers_suite_test.go+1−1 providers/providers_test.go+138−6 providers/srht.go+109 providers/srht_test.go+77 providers/util_test.go+33 tools/tools.go−7 validator.go+4−1 validator_test.go+21
.devcontainer/Dockerfile+1−1
@@ -1,4 +1,4 @@
1−FROM mcr.microsoft.com/vscode/devcontainers/go:1-1.21
1+FROM mcr.microsoft.com/vscode/devcontainers/go:1-1.26
22
33SHELL ["/bin/bash", "-o", "pipefail", "-c"]
44
.github/FUNDING.ymlnew file+15
@@ -0,0 +1,15 @@
1+# These are supported funding model platforms
2+
3+github: tuunit # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4+patreon: # Replace with a single Patreon username
5+open_collective: oauth2-proxy # Replace with a single Open Collective username
6+ko_fi: # Replace with a single Ko-fi username
7+tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+liberapay: # Replace with a single Liberapay username
10+issuehunt: # Replace with a single IssueHunt username
11+lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
12+polar: # Replace with a single Polar username
13+buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
14+thanks_dev: # Replace with a single thanks.dev username
15+custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
.github/ISSUE_TEMPLATE/bug-report.yml+1
@@ -18,6 +18,7 @@ body:
1818 - azure
1919 - bitbucket
2020 - digitalocean
21+ - entra-id
2122 - facebook
2223 - gitea
2324 - github
.github/ISSUE_TEMPLATE/config.yml+2−2
@@ -1,6 +1,6 @@
11blank_issues_enabled: false
22contact_links:
3− - name: OAuth2-Proxy Slack
4− url: https://gophers.slack.com/messages/CM2RSS25N
3+ - name: OAuth2 Proxy Slack
4+ url: https://cloud-native.slack.com/archives/C098Y5URZ2N
55 about: Feel free to ask any questions here.
66
.github/ISSUE_TEMPLATE/configuration-support.yml+1
@@ -18,6 +18,7 @@ body:
1818 - azure
1919 - bitbucket
2020 - digitalocean
21+ - entra-id
2122 - facebook
2223 - gitea
2324 - github
.github/ISSUE_TEMPLATE/feature-request.yml+1
@@ -34,6 +34,7 @@ body:
3434 - azure
3535 - bitbucket
3636 - digitalocean
37+ - entra-id
3738 - facebook
3839 - gitea
3940 - github
.github/PULL_REQUEST_TEMPLATE.md+3−2
@@ -20,7 +20,8 @@
2020<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->
2121<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->
2222
23−- [ ] My change requires a change to the documentation or CHANGELOG.
24−- [ ] I have updated the documentation/CHANGELOG accordingly.
23+- [ ] I have added an entry for my changes to the [CHANGELOG.md](https://github.com/oauth2-proxy/oauth2-proxy/blob/master/CHANGELOG.md).
24+- [ ] I have [signed off](https://github.com/apps/dco) all my commits.
2525- [ ] I have created a feature (non-master) branch for my PR.
26+- [ ] I have used [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/#examples) for the PR title.
2627- [ ] I have written tests for my code changes.
.github/renovate.json5+9
@@ -46,6 +46,15 @@
4646 depNameTemplate: "alpine",
4747 datasourceTemplate: "docker",
4848 },
49+ {
50+ customType: "regex",
51+ fileMatch: [
52+ "^Makefile",
53+ ],
54+ matchStrings: [
55+ "# renovate: datasource=(?<datasource>.*?) depName=(?<depName>.*?)\\s+?GOLANGCILINT_VERSION \\?= (?<currentValue>.*)\\s",
56+ ],
57+ },
4958 {
5059 customType: "regex",
5160 fileMatch: ["(^|/)\\.github/workflows/[^/]+\\.ya?ml$"],
.github/workflows/ci.yamldeleted−75
@@ -1,75 +0,0 @@
1−name: Continuous Integration
2−
3−on:
4− push:
5− branches:
6− - '**'
7− # - $default-branch
8− pull_request:
9− branches:
10− - '**'
11− # - $default-branch
12−
13−jobs:
14− build:
15− env:
16− COVER: true
17− runs-on: ubuntu-latest
18− steps:
19−
20− - name: Check out code
21− uses: actions/checkout@v4
22−
23− - name: Set up Go
24− uses: actions/setup-go@v5
25− with:
26− # renovate: datasource=golang-version depName=golang
27− go-version: 1.22.4
28− id: go
29−
30− - name: Get dependencies
31− env:
32− # renovate: datasource=github-tags depName=golangci/golangci-lint
33− GOLANGCI_LINT_VERSION: v1.55.2
34− # renovate: datasource=github-tags depName=codeclimate/test-reporter
35− CODECLIMATE_VERSION: v1.0.1
36− run: |
37− curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin ${GOLANGCI_LINT_VERSION}
38− curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-${CODECLIMATE_VERSION#v}-linux-amd64 > ./cc-test-reporter
39− chmod +x ./cc-test-reporter
40−
41− - name: Verify Code Generation
42− run: |
43− make verify-generate
44−
45− - name: Lint
46− run: |
47− make lint
48−
49− - name: Build
50− run: |
51− make build
52−
53− - name: Test
54− env:
55− CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
56− run: |
57− ./.github/workflows/test.sh
58−
59− docker:
60− runs-on: ubuntu-latest
61− steps:
62−
63− - name: Check out code
64− uses: actions/checkout@v4
65−
66− - name: Set up QEMU
67− uses: docker/setup-qemu-action@v3
68−
69− - name: Set up Docker Buildx
70− id: buildx
71− uses: docker/setup-buildx-action@v3
72−
73− - name: Docker Build
74− run: |
75− make docker
.github/workflows/ci.ymlnew file+118
@@ -0,0 +1,118 @@
1+name: Continuous Integration
2+
3+on:
4+ push:
5+ branches:
6+ - '**'
7+ pull_request:
8+ branches:
9+ - '**'
10+ workflow_dispatch:
11+
12+permissions:
13+ contents: read
14+ id-token: write
15+ security-events: write
16+
17+jobs:
18+ build:
19+ runs-on: ubuntu-latest
20+ steps:
21+ - name: Check out code
22+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
23+ with:
24+ fetch-depth: 0
25+
26+ - name: Get Go version
27+ run: |
28+ version=$(grep "^go " go.mod | cut -d' ' -f2 | cut -d. -f1,2)
29+ echo "version=${version}" >> "$GITHUB_OUTPUT"
30+ id: go-version
31+
32+ - name: Set up Go
33+ uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
34+ with:
35+ go-version: ${{ steps.go-version.outputs.version }}
36+ check-latest: true
37+
38+ - name: Verify Code Generation
39+ run: |
40+ make verify-generate
41+
42+ - name: Lint
43+ run: |
44+ make lint
45+
46+ - name: Build
47+ if: (!startsWith(github.head_ref, 'release'))
48+ run: |
49+ make build
50+
51+ # For release testing
52+ - name: Build All
53+ if: github.base_ref == 'master' && startsWith(github.head_ref, 'release')
54+ run: |
55+ make release
56+
57+ - name: Test
58+ env:
59+ COVER: true
60+ run: |
61+ make test
62+
63+ - name: Generate Coverage Report
64+ if: github.event_name == 'push'
65+ run: |
66+ go install github.com/jandelgado/gcov2lcov@25681830fb515e3d4c117e136b4f049e21efb4d0
67+ gcov2lcov -infile=c.out -outfile=lcov.info
68+
69+ - name: Upload Coverage Report
70+ if: github.event_name == 'push'
71+ uses: qltysh/qlty-action/coverage@08a0a862c159eae9b9003081da6663d96efef637 # v2.3.0
72+ with:
73+ oidc: true
74+ files: lcov.info
75+
76+ - name: Run Trivy vulnerability scanner
77+ if: (!startsWith(github.head_ref, 'release'))
78+ uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
79+ with:
80+ scan-type: 'rootfs'
81+ scan-ref: './oauth2-proxy'
82+ severity: 'CRITICAL,HIGH'
83+ hide-progress: true
84+ format: 'sarif'
85+ output: 'trivy-results.sarif'
86+ exit-code: '0'
87+
88+ - name: Upload Trivy scan results
89+ if: (!startsWith(github.head_ref, 'release'))
90+ uses: github/codeql-action/upload-sarif@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7
91+ with:
92+ sarif_file: 'trivy-results.sarif'
93+
94+ docker:
95+ runs-on: ubuntu-latest
96+ steps:
97+ - name: Check out code
98+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
99+ with:
100+ fetch-depth: 0
101+
102+ - name: Set up QEMU
103+ uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4.2.0
104+
105+ - name: Set up Docker Buildx
106+ id: buildx
107+ uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4.2.0
108+
109+ - name: Docker Build
110+ if: (!startsWith(github.head_ref, 'release'))
111+ run: |
112+ make build-docker
113+
114+ # For release testing
115+ - name: Docker Build All
116+ if: github.base_ref == 'master' && startsWith(github.head_ref, 'release')
117+ run: |
118+ make build-docker-all
.github/workflows/codeql.yml+18−15
@@ -2,10 +2,22 @@ name: "Code scanning - action"
22
33on:
44 push:
5− branches: [master, ]
5+ branches:
6+ - master
7+ paths-ignore:
8+ - '.devcontainer/**'
9+ - '.vscode/**'
10+ - 'contrib/**'
11+ - 'docs/**'
612 pull_request:
713 # The branches below must be a subset of the branches above
8− branches: [master]
14+ branches:
15+ - master
16+ paths-ignore:
17+ - '.devcontainer/**'
18+ - '.vscode/**'
19+ - 'contrib/**'
20+ - 'docs/**'
921 schedule:
1022 - cron: '0 15 * * 2'
1123
@@ -20,27 +32,18 @@ jobs:
2032
2133 steps:
2234 - name: Checkout repository
23− uses: actions/checkout@v4
24− with:
25− # We must fetch at least the immediate parents so that if this is
26− # a pull request then we can checkout the head.
27− fetch-depth: 2
28−
29− # If this run was triggered by a pull request event, then checkout
30− # the head of the pull request instead of the merge commit.
31− - run: git checkout HEAD^2
32− if: ${{ github.event_name == 'pull_request' }}
35+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3336
3437 # Initializes the CodeQL tools for scanning.
3538 - name: Initialize CodeQL
36− uses: github/codeql-action/init@v3
39+ uses: github/codeql-action/init@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7
3740 with:
3841 languages: go
3942
4043 # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
4144 # If this step fails, then you should remove it and run the build manually (see below)
4245 - name: Autobuild
43− uses: github/codeql-action/autobuild@v3
46+ uses: github/codeql-action/autobuild@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7
4447
4548 # ℹ️ Command-line programs to run using the OS shell.
4649 # 📚 https://git.io/JvXDl
@@ -54,4 +57,4 @@ jobs:
5457 # make release
5558
5659 - name: Perform CodeQL Analysis
57− uses: github/codeql-action/analyze@v3
60+ uses: github/codeql-action/analyze@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7
.github/workflows/create-release.yml+5−3
@@ -17,7 +17,7 @@ jobs:
1717 runs-on: ubuntu-latest
1818 steps:
1919 - name: Check out code
20− uses: actions/checkout@v4
20+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2121 with:
2222 ref: master
2323 fetch-depth: 0
@@ -54,7 +54,7 @@ jobs:
5454 git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
5555
5656 - name: Setup node
57− uses: actions/setup-node@v4
57+ uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
5858 with:
5959 node-version-file: docs/package.json
6060
@@ -66,7 +66,7 @@ jobs:
6666 VERSION=${FULL_VERSION%.*}.x
6767
6868 if [ ! -d "versioned_docs/version-${VERSION}" ]; then
69− npm ci
69+ npm install
7070 npm run docusaurus docs:version ${VERSION}
7171
7272 git add .
@@ -90,6 +90,8 @@ jobs:
9090 ## Important Notes
9191
9292 ## Breaking Changes
93+
94+ ## Changes since v${VERSION}
9395 EOF
9496
9597 echo -e "$(cat /tmp/CHANGELOG.prepend)\n\n$(cat CHANGELOG.md)" > CHANGELOG.md
.github/workflows/docs.yaml → .github/workflows/docs.ymlrenamed+11−13
@@ -14,44 +14,42 @@ jobs:
1414 if: github.event_name == 'pull_request'
1515 runs-on: ubuntu-latest
1616 steps:
17− - uses: actions/checkout@v4
17+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
1818
1919 - name: Setup Pages
2020 id: pages
21− uses: actions/configure-pages@v5
21+ uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0
2222
23− - uses: actions/setup-node@v4
23+ - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
2424 with:
2525 # renovate: datasource=node-version depName=node
26− node-version: 20
27− cache: npm
28− cache-dependency-path: "./docs/package-lock.json"
26+ node-version: 24
2927
3028 - name: Test Build
3129 working-directory: ./docs
3230 run: |
33− npm ci
31+ npm install
3432 npm run build
3533
3634 build-docs:
3735 if: github.event_name == 'push' || github.event_name == 'workflow_dispatch'
3836 runs-on: ubuntu-latest
3937 steps:
40− - uses: actions/checkout@v4
38+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
4139
42− - uses: actions/setup-node@v4
40+ - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
4341 with:
4442 # renovate: datasource=node-version depName=node
45− node-version: 20
43+ node-version: 24
4644
4745 - name: Build docusaurus
4846 working-directory: ./docs
4947 run: |
50− npm ci
48+ npm install
5149 npm run build
5250
5351 - name: Upload artifact
54− uses: actions/upload-pages-artifact@v3
52+ uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
5553 with:
5654 path: ./docs/build
5755
@@ -67,4 +65,4 @@ jobs:
6765 steps:
6866 - name: Deploy to GitHub Pages
6967 id: deployment
70− uses: actions/deploy-pages@v4
68+ uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0
.github/workflows/e2e.ymlnew file+14
@@ -0,0 +1,14 @@
1+name: E2E
2+
3+on:
4+ issue_comment:
5+ types: [created]
6+
7+jobs:
8+ e2e:
9+ uses: oauth2-proxy/e2e-suite/.github/workflows/e2e.yml@main
10+ permissions:
11+ contents: read
12+ statuses: write
13+ issues: write
14+ pull-requests: write
.github/workflows/labeler.yaml → .github/workflows/labeler.ymlrenamed+1−1
@@ -9,7 +9,7 @@ jobs:
99 pull-requests: write
1010 runs-on: ubuntu-latest
1111 steps:
12− - uses: actions/labeler@v5
12+ - uses: actions/labeler@bf12e9b00b37c5c0ca2b87b79b2daf7891dbda13 # v7.0.0
1313 with:
1414 sync-labels: true
1515 dot: true
.github/workflows/nightly.yml+6−6
@@ -12,21 +12,21 @@ jobs:
1212 if: github.repository == 'oauth2-proxy/oauth2-proxy'
1313 steps:
1414 - name: Check out code
15− uses: actions/checkout@v4
15+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
1616 with:
1717 ref: master
1818 fetch-depth: 0
1919 fetch-tags: true
2020
2121 - name: Set up QEMU
22− uses: docker/setup-qemu-action@v3
22+ uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4.2.0
2323
2424 - name: Set up Docker Buildx
2525 id: buildx
26− uses: docker/setup-buildx-action@v3
26+ uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4.2.0
2727
2828 - name: Login to quay.io
29− uses: docker/login-action@v3
29+ uses: docker/login-action@dbcb813823bdd20940b903addbd779551569679f # v4.6.0
3030 with:
3131 registry: quay.io/oauth2-proxy
3232 username: ${{ secrets.REGISTRY_USERNAME_NIGHTLY }}
@@ -34,8 +34,8 @@ jobs:
3434
3535 - name: Build images
3636 run: |
37− make docker-nightly-build
37+ make nightly-build
3838
3939 - name: Push images
4040 run: |
41− make docker-nightly-push
41+ make nightly-push
.github/workflows/publish-release.yml+24−23
@@ -14,48 +14,49 @@ permissions:
1414
1515jobs:
1616 publish:
17− if: github.event.pull_request.merged && startsWith(github.event.pull_request.head.ref, 'release/')
17+ if: github.event.pull_request.merged && startsWith(github.event.pull_request.head.ref, 'release/') && github.event.pull_request.head.repo.full_name == github.repository
1818 runs-on: ubuntu-latest
1919 outputs:
2020 tag: ${{ steps.tag.outputs.version }}
2121 steps:
2222 - name: Check out code
23− uses: actions/checkout@v4
23+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2424 with:
2525 ref: ${{ github.event.pull_request.merge_commit_sha }}
2626 fetch-depth: 0
2727 fetch-tags: true
2828
2929 - name: Tag release
30+ env:
31+ BRANCH: ${{ github.event.pull_request.head.ref }}
3032 run: |
3133 # Set up github-actions[bot] user
3234 git config --local user.name "github-actions[bot]"
3335 git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
3436
3537 # Get the version from the branch name
36− branch="${{ github.event.pull_request.head.ref }}"
37− version="${branch#release/}"
38+ version="${BRANCH#release/}"
3839 echo ${version}
3940
4041 # Tag and create release
4142 git tag -a "${version}" -m "Release ${version}"
4243 echo "version=${version}" >> $GITHUB_OUTPUT
4344 id: tag
44−
45− - name: Set up go
46− uses: actions/setup-go@v5
47− with:
48− go-version-file: go.mod
4945
50− - name: Get dependencies
51− env:
52− GOLANGCI_LINT_VERSION: v1.55.2
46+ - name: Get Go version
5347 run: |
54− curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin ${GOLANGCI_LINT_VERSION}
55− curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
56− chmod +x ./cc-test-reporter
48+ version=$(grep "^go " go.mod | cut -d' ' -f2 | cut -d. -f1,2)
49+ echo "version=${version}" >> "$GITHUB_OUTPUT"
50+ id: go-version
5751
58− # Install go dependencies
52+ - name: Set up Go
53+ uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
54+ with:
55+ go-version: ${{ steps.go-version.outputs.version }}
56+ check-latest: true
57+
58+ - name: Get go dependencies
59+ run: |
5960 go mod download
6061
6162 - name: Build Artifacts
@@ -63,7 +64,7 @@ jobs:
6364
6465 # Upload artifacts in case of workflow failure
6566 - name: Upload Artifacts
66− uses: actions/upload-artifact@v4
67+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
6768 with:
6869 name: oauth2-proxy-artifacts
6970 path: |
@@ -99,21 +100,21 @@ jobs:
99100 runs-on: ubuntu-latest
100101 steps:
101102 - name: Check out code
102− uses: actions/checkout@v4
103+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
103104 with:
104105 ref: ${{ needs.publish.outputs.tag }}
105106 fetch-depth: 0
106107 fetch-tags: true
107108
108109 - name: Set up QEMU
109− uses: docker/setup-qemu-action@v3
110+ uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4.2.0
110111
111112 - name: Set up Docker Buildx
112113 id: buildx
113− uses: docker/setup-buildx-action@v3
114+ uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4.2.0
114115
115116 - name: Login to quay.io
116− uses: docker/login-action@v3
117+ uses: docker/login-action@dbcb813823bdd20940b903addbd779551569679f # v4.6.0
117118 with:
118119 registry: quay.io/oauth2-proxy
119120 username: ${{ secrets.REGISTRY_USERNAME }}
@@ -121,8 +122,8 @@ jobs:
121122
122123 - name: Build images
123124 run: |
124− make docker-all
125+ make build-docker-all
125126
126127 - name: Push images
127128 run: |
128− make docker-push-all
129+ make push-docker-all
.github/workflows/stale.yml+7−3
@@ -10,8 +10,12 @@ jobs:
1010 runs-on: ubuntu-latest
1111
1212 steps:
13− - uses: actions/stale@v9
13+ - uses: actions/stale@4391f3da665fdf50b6810c1a66712fb9ba21aa93 # v11.0.0
1414 with:
1515 repo-token: ${{ secrets.GITHUB_TOKEN }}
16− stale-issue-message: 'This issue has been inactive for 60 days. If the issue is still relevant please comment to re-activate the issue. If no action is taken within 7 days, the issue will be marked closed.'
17− stale-pr-message: 'This pull request has been inactive for 60 days. If the pull request is still relevant please comment to re-activate the pull request. If no action is taken within 7 days, the pull request will be marked closed.'
16+ days-before-stale: 180
17+ days-before-close: 14
18+ stale-issue-message: 'This issue has been inactive for 180 days. If the issue is still relevant please comment to re-activate the issue. If no action is taken within 14 days, the issue will be marked closed.'
19+ stale-pr-message: 'This pull request has been inactive for 180 days. If the pull request is still relevant please comment to re-activate the pull request. If no action is taken within 14 days, the pull request will be marked closed.'
20+ exempt-issue-labels: bug,high-priority
21+ exempt-pr-labels: bug,high-priority
.github/workflows/test.shdeleted−26
@@ -1,26 +0,0 @@
1−#!/bin/bash
2−# manually exiting from script, because after-build needs to run always
3−set +e
4−
5−if [ -z $CC_TEST_REPORTER_ID ]; then
6− echo "1. CC_TEST_REPORTER_ID is unset, skipping"
7−else
8− echo "1. Running before-build"
9− ./cc-test-reporter before-build
10−fi
11−
12−echo "2. Running test"
13−make test
14−TEST_STATUS=$?
15−
16−if [ -z $CC_TEST_REPORTER_ID ]; then
17− echo "3. CC_TEST_REPORTER_ID is unset, skipping"
18−else
19− echo "3. Running after-build"
20− ./cc-test-reporter after-build --exit-code $TEST_STATUS --prefix $(go list -m)
21−fi
22−
23−if [ "$TEST_STATUS" -ne 0 ]; then
24− echo "Test failed, status code: $TEST_STATUS"
25− exit $TEST_STATUS
26−fi
.gitignore+1
@@ -17,6 +17,7 @@ c.out
1717# Folders
1818_obj
1919_test
20+.DS_Store
2021.idea/
2122.vscode/*
2223!/.vscode/tasks.json
.golangci.yml+69−38
@@ -1,46 +1,77 @@
1−run:
2− deadline: 120s
1+version: "2"
32linters:
3+ default: none
44 enable:
5− - govet
6− - ineffassign
7− - goconst
8− - gofmt
9− - goimports
10− - gosec
11− - gosimple
12− - staticcheck
13− - typecheck
14− - unused
155 - bodyclose
6+ - copyloopvar
167 - dogsled
8+ - goconst
9+ - gocritic
1710 - goprintffuncname
11+ - gosec
12+ - govet
13+ - ineffassign
1814 - misspell
1915 - prealloc
20− - exportloopref
21− - stylecheck
22− - unconvert
23− - gocritic
2416 - revive
25− disable-all: true
26−issues:
27− exclude-rules:
28− - path: _test\.go
29− linters:
30− - scopelint
31− - bodyclose
32− - unconvert
33− - gocritic
34− - gosec
35− - goconst
36− - revive
37− - path: _test\.go
38− linters:
39− - revive
40− text: "dot-imports:"
41− # If we have tests in shared test folders, these can be less strictly linted
42− - path: tests/.*_tests\.go
43− linters:
44− - revive
45− - bodyclose
46− - stylecheck
17+ - staticcheck
18+ - unconvert
19+ - unused
20+ exclusions:
21+ generated: lax
22+ presets:
23+ - comments
24+ - common-false-positives
25+ - legacy
26+ - std-error-handling
27+ rules:
28+ - linters:
29+ - bodyclose
30+ - goconst
31+ - gocritic
32+ - gosec
33+ - revive
34+ - scopelint
35+ - unconvert
36+ path: _test\.go
37+ - linters:
38+ - revive
39+ path: _test\.go
40+ text: "dot-imports:"
41+ # # If we have tests in shared test folders, these can be less strictly linted
42+ - linters:
43+ - bodyclose
44+ - revive
45+ - staticcheck
46+ path: tests/.*_tests\.go
47+ # See https://github.com/oauth2-proxy/oauth2-proxy/issues/3060
48+ # https://staticcheck.dev/docs/checks/#QF1008
49+ - linters:
50+ - staticcheck
51+ text: QF1008
52+ - linters:
53+ - revive
54+ path: util/.*\.go$
55+ text: "var-naming: avoid meaningless package names"
56+ # pkg/version conflicts with go/version (added in Go 1.22)
57+ - linters:
58+ - revive
59+ path: pkg/version/.*\.go$
60+ text: "var-naming: avoid package names that conflict with"
61+ - linters:
62+ - prealloc
63+ path: _test\.go
64+ paths:
65+ - third_party$
66+ - builtin$
67+ - examples$
68+formatters:
69+ enable:
70+ - gofmt
71+ - goimports
72+ exclusions:
73+ generated: lax
74+ paths:
75+ - third_party$
76+ - builtin$
77+ - examples$
CHANGELOG.md+585
@@ -6,11 +6,596 @@
66
77## Breaking Changes
88
9+## Changes since v7.15.4
10+
11+# V7.15.4
12+
13+## Release Highlights
14+
15+- 🔵 Golang version upgrade to v1.26.7
16+ - Upgrade of all dependencies to their latest versions
17+- 🕵️‍♀️ Vulnerabilities have been addressed
18+ - [CVE-2026-33818](https://nvd.nist.gov/vuln/detail/CVE-2026-33818)
19+ - [CVE-2026-39821](https://nvd.nist.gov/vuln/detail/CVE-2026-39821)
20+ - [CVE-2026-39822](https://nvd.nist.gov/vuln/detail/CVE-2026-39822)
21+ - [CVE-2026-42505](https://nvd.nist.gov/vuln/detail/CVE-2026-42505)
22+ - [CVE-2026-46600](https://nvd.nist.gov/vuln/detail/CVE-2026-46600)
23+ - [CVE-2026-56852](https://nvd.nist.gov/vuln/detail/CVE-2026-56852)
24+ - [CVE-2026-56853](https://nvd.nist.gov/vuln/detail/CVE-2026-56853)
25+ - [CVE-2026-56858](https://nvd.nist.gov/vuln/detail/CVE-2026-56858)
26+ - [CVE-2026-56859](https://nvd.nist.gov/vuln/detail/CVE-2026-56859)
27+ - [CVE-2026-56860](https://nvd.nist.gov/vuln/detail/CVE-2026-56860)
28+ - [CVE-2026-56862](https://nvd.nist.gov/vuln/detail/CVE-2026-56862)
29+
30+## Important Notes
31+
32+## Breaking Changes
33+
34+## Changes since v7.15.3
35+
36+- [#3493](https://github.com/oauth2-proxy/oauth2-proxy/pull/3493) chore(deps): update gomod @tuunit
37+
38+# V7.15.3
39+
40+## Release Highlights
41+
42+- 🔵 Golang version upgrade to v1.26.4
43+ - Upgrade of all dependencies to their latest versions
44+- 🕵️‍♀️ Vulnerabilities have ben addressed
45+ - [CVE-2026-33811](https://nvd.nist.gov/vuln/detail/)
46+ - [CVE-2026-33814](https://nvd.nist.gov/vuln/detail/)
47+ - [CVE-2026-39820](https://nvd.nist.gov/vuln/detail/)
48+ - [CVE-2026-39836](https://nvd.nist.gov/vuln/detail/)
49+ - [CVE-2026-42499](https://nvd.nist.gov/vuln/detail/)
50+ - [CVE-2026-42504](https://nvd.nist.gov/vuln/detail/)
51+ - [CVE-2026-39823](https://nvd.nist.gov/vuln/detail/)
52+ - [CVE-2026-39826](https://nvd.nist.gov/vuln/detail/)
53+ - [CVE-2026-39825](https://nvd.nist.gov/vuln/detail/)
54+ - [CVE-2026-27145](https://nvd.nist.gov/vuln/detail/)
55+ - [CVE-2026-42507](https://nvd.nist.gov/vuln/detail/)
56+
57+## Important Notes
58+
59+## Breaking Changes
60+
61+## Changes since v7.15.2
62+
63+- [#3477](https://github.com/oauth2-proxy/oauth2-proxy/pull/3477) chore(dep): bump go to 1.26 and migrate of reverse proxy handling
64+
65+# V7.15.2
66+
67+## Release Highlights
68+
69+- 🔵 Golang version upgrade to v1.25.9
70+ - Upgrade of all dependencies to their latest versions
71+ - [CVE-2026-34986](https://nvd.nist.gov/vuln/detail/CVE-2026-34986)
72+ - [CVE-2026-32281](https://nvd.nist.gov/vuln/detail/CVE-2026-32281)
73+ - [CVE-2026-32289](https://nvd.nist.gov/vuln/detail/CVE-2026-32289)
74+ - [CVE-2026-32288](https://nvd.nist.gov/vuln/detail/CVE-2026-32288)
75+ - [CVE-2026-32280](https://nvd.nist.gov/vuln/detail/CVE-2026-32280)
76+ - [CVE-2026-32282](https://nvd.nist.gov/vuln/detail/CVE-2026-32282)
77+ - [CVE-2026-32283](https://nvd.nist.gov/vuln/detail/CVE-2026-32283)
78+- 🕵️‍♀️ Vulnerabilities have been addressed
79+
80+## Important Notes
81+
82+We have had security audits performed on OAuth2 Proxy in the past couple of weeks and as a result we have fixed
83+several CRITICAL vulnerabilities.
84+
85+The security vulnerabilities include multiple authentication bypasses and a potential session fixation attack.
86+For more details and to identify if you are effects, we urge all users of OAuth2 Proxy to read the security
87+disclosures.
88+
89+- (Critical) [GHSA-5hvv-m4w4-gf6v](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-5hvv-m4w4-gf6v) fix: health check user-agent authentication bypass
90+- (Critical) [GHSA-7x63-xv5r-3p2x](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-7x63-xv5r-3p2x) fix: authentication bypass via X-Forwarded-Uri header spoofing
91+- (High) [GHSA-pxq7-h93f-9jrg](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-pxq7-h93f-9jrg) fix: fragment evaluation as part of the allowed routes
92+- (Moderate) [GHSA-c5c4-8r6x-56w3](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-c5c4-8r6x-56w3) fix: email validation bypass via malformed multi-@ email claims
93+
94+Furthermore, for improving the security of OAuth2 Proxy we introduced a new flag `--trusted-proxy-ip` that allows users
95+to explicitly specify trusted reverse proxy IPs for the `X-Forwarded-*` headers. This is an important step to prevent
96+potential header spoofing attacks and to ensure that OAuth2 Proxy only trusts headers from known and trusted sources.
97+We highly recommend users to review their deployment architecture and consider using this flag to enhance the security
98+of their OAuth2 Proxy instances. Check the docs for more details: https://oauth2-proxy.github.io/oauth2-proxy/configuration/overview#proxy-options
99+
100+Furthermore, we want to thank everyone who contributed to the audits and reported potential issues to make open source
101+software like OAuth2 Proxy more secure for everyone.
102+
103+## Breaking Changes
104+
105+## Changes since v7.15.1
106+
107+- [#3411](https://github.com/oauth2-proxy/oauth2-proxy/pull/3411) chore(deps): update gomod dependencies (@tuunit)
108+- [#3333](https://github.com/oauth2-proxy/oauth2-proxy/pull/3333) fix: invalidate session on fatal OAuth2 refresh errors (@frhack)
109+- [GHSA-f24x-5g9q-753f](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-f24x-5g9q-753f) fix: clear session cookie at beginning of signinpage handler (@fnoehWM / @bella-WI / @tuunit)
110+- [GHSA-5hvv-m4w4-gf6v](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-5hvv-m4w4-gf6v) fix: health check user-agent authentication bypass (@tuunit)
111+- [GHSA-7x63-xv5r-3p2x](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-7x63-xv5r-3p2x) fix: authentication bypass via X-Forwarded-Uri header spoofing (@tuunit)
112+- [GHSA-pxq7-h93f-9jrg](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-pxq7-h93f-9jrg) fix: fragment evaluation as part of the allowed routes (@tuunit)
113+- [GHSA-c5c4-8r6x-56w3](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-c5c4-8r6x-56w3) fix: email validation bypass via malformed multi-@ email claims (@tuunit)
114+
115+# V7.15.1
116+
117+## Release Highlights
118+
119+- 🐛 Squashed some bugs
120+- 🕵️‍♀️ Vulnerabilities have been addressed
121+ - [CVE-2026-33186](https://nvd.nist.gov/vuln/detail/CVE-2026-33186)
122+ OAuth2 Proxy was not impacted by this vulnerability as it isn't in the path of execution
123+
124+## Important Notes
125+
126+## Breaking Changes
127+
128+## Changes since v7.15.0
129+
130+- [#3382](https://github.com/oauth2-proxy/oauth2-proxy/pull/3382) chore(deps): update gomod and golangci/golangci-lint to v2.11.4 (@tuunit)
131+- [#3374](https://github.com/oauth2-proxy/oauth2-proxy/pull/3374) fix: handle Unix socket RemoteAddr in IP resolution (@H1net)
132+- [#3381](https://github.com/oauth2-proxy/oauth2-proxy/pull/3381) fix: do not log error for backend logout 204 (@artificiosus)
133+- [#3327](https://github.com/oauth2-proxy/oauth2-proxy/pull/3327) fix: improve logging when session refresh token is missing (@yosri-brh)
134+- [#2767](https://github.com/oauth2-proxy/oauth2-proxy/pull/2767) fix: propagate errors during route building (@sybereal)
135+
136+# V7.15.0
137+
138+## Release Highlights
139+
140+- 🔒 OIDC JWT signing algorithms can now be configured
141+- 🍪 CSRF cookie improvements (SameSite option, proper expiration validation)
142+- 🧪 Configuration validation flag: --config-test
143+- 🔌 Unix socket file mode support
144+- 👤 Session state can now be extend with arbitrary claims from ID Token and upstream IDP user profiles endpoint
145+ - This opens the door for multiple features like:
146+ - Additional arbitrary header values for any claims your IDP provides
147+ - Extended OAuth2 Proxy UserInfo endpoint with all additional claims
148+ - Read the docs [here](https://oauth2-proxy.github.io/oauth2-proxy/configuration/alpha-config#how-to-utilize-arbitrary-claims-provided-by-your-identity-provider)
149+
150+## Important Notes
151+
152+CSRF cookie validation now correctly uses `CSRFExpire` instead of `Expire`. If you relied on the previous behavior, review your session timeout configuration.
153+Check the [documentation(https://oauth2-proxy.github.io/oauth2-proxy/configuration/overview#cookie-options) for `cookie-csrf-expire`.
154+
155+## Breaking Changes
156+
157+## Changes since v7.14.3
158+
159+- [#3352](https://github.com/oauth2-proxy/oauth2-proxy/pull/3352) fix: backend logout URL call on sign out (#3172)(@vsejpal)
160+- [#3332](https://github.com/oauth2-proxy/oauth2-proxy/pull/3332) ci: distribute windows binary with .exe extension (@igitur)
161+- [#2685](https://github.com/oauth2-proxy/oauth2-proxy/pull/2685) feat: allow arbitrary claims from the IDToken and IdentityProvider UserInfo endpoint to be added to the session state (@vegetablest)
162+- [#3278](https://github.com/oauth2-proxy/oauth2-proxy/pull/3278) feat: possibility to inject id_token in redirect url during sign out (@albanf)
163+- [#2851](https://github.com/oauth2-proxy/oauth2-proxy/pull/2851) feat: add support for specifying allowed OIDC JWT signing algorithms (#2753) (@andoks / @tuunit)
164+- [#3369](https://github.com/oauth2-proxy/oauth2-proxy/pull/3369) fix: use CSRFExpire instead of Expire for CSRF cookie validation (@Br1an67)
165+- [#3365](https://github.com/oauth2-proxy/oauth2-proxy/pull/3365) fix: filter empty strings from allowed groups (@Br1an67)
166+- [#3338](https://github.com/oauth2-proxy/oauth2-proxy/pull/3338) feat: add --config-test flag for validating configuration (@MayorFaj)
167+- [#3347](https://github.com/oauth2-proxy/oauth2-proxy/pull/3347) feat: add same site option for csrf cookies (@jvnoije)
168+- [#3376](https://github.com/oauth2-proxy/oauth2-proxy/pull/3376) feat: allow setting unix socket file mode when declaring listener (@Tristan971 / @tuunit)
169+
170+# V7.14.3
171+
172+## Release Highlights
173+
174+- 🔵 Go1.25.7 and upgrade of dependencies to latest versions
175+ - Fixes [CVE-2025-68121](https://nvd.nist.gov/vuln/detail/cve-2025-68121)
176+- 🐛 Bug fixes
177+ - Allow Redis URL parameters to configure username, password and max idle connection timeout if the matching configuration is empty.
178+
179+## Important Notes
180+
181+We improved our supply chain security by added additional checks to prevent potential command injection in the publish release workflow and to ensure that it can only be triggered from branches originating in the local repository. This potential issue was reported by automated systems as well as a couple of security researchers, and we want to thank everyone for their diligence in looking out for the security of the project. Especially Aastha Aggarwal for her detailed report and follow-up. @Aastha2602
182+
183+
184+## Breaking Changes
185+
186+## Changes since v7.14.2
187+
188+- [#3183](https://github.com/oauth2-proxy/oauth2-proxy/pull/3183) fix: allow URL parameters to configure username, password and max idle connection timeout if the matching configuration is empty.
189+
190+# V7.14.2
191+
192+## Release Highlights
193+
194+- Revert AuthOnly endpoint change from v7.14.1 that caused issues when using `skip-provider-button` enabled
195+
196+## Important Notes
197+
198+- This release reverts the change made in v7.14.1 that caused issues when using the `skip-provider-button` enabled. Now, when a session does not exist, the AuthOnly endpoint will send a 401 status code as expected instead of a 302 redirect. And instead we extended the documentation to clarify the behavior when using `nginx` with `auth_request` and `skip-provider-button` and how to properly configure redirects for browser and API routes.
199+
200+## Breaking Changes
201+
202+## Changes since v7.14.1
203+
204+- [#3314](https://github.com/oauth2-proxy/oauth2-proxy/pull/3314) revert: fix: skip provider button auth only redirect (#3309) (@StefanMarkmann / @tuunit)
205+- [#3315](https://github.com/oauth2-proxy/oauth2-proxy/pull/3315) docs: clarify browser vs API routes for nginx auth_request redirects (@StefanMarkmann)
206+
207+# V7.14.1
208+
209+## Release Highlights
210+
211+- 🔵 Go1.25.6 and upgrade of dependencies to latest versions
212+- 🐛 Bug fixes
213+ - AuthOnly now starts the auth flow and send status code 302 if no session exists and skip-provider-button is true
214+ - Fixed static upstream validation issue due to incorrect defaults
215+
216+## Important Notes
217+
218+## Breaking Changes
219+
220+## Changes since v7.14.0
221+
222+- [#3309](https://github.com/oauth2-proxy/oauth2-proxy/pull/3309) fix: Return 302 redirect from AuthOnly endpoint when skip-provider-button is true (@StefanMarkmann)
223+- [#3302](https://github.com/oauth2-proxy/oauth2-proxy/pull/3302) fix: static upstreams failing validation due to `passHostHeader` and `proxyWebSockets` defaults being set incorrectly (@sourava01 / @tuunit)
224+- [#3312](https://github.com/oauth2-proxy/oauth2-proxy/pull/3312) chore(deps): upgrade to go1.25.6 and latest dependencies (@tuunit)
225+
226+# V7.14.0
227+
228+## Release Highlights
229+
230+- 🕵️‍♀️ Vulnerabilities have been addressed
231+ - [CVE-2025-61729](https://access.redhat.com/security/cve/cve-2025-61729)
232+ - [CVE-2025-61727](https://access.redhat.com/security/cve/cve-2025-61727)
233+ - [CVE-2025-47914](https://access.redhat.com/security/cve/cve-2025-47914)
234+ - [CVE-2025-58181](https://access.redhat.com/security/cve/cve-2025-58181)
235+- 🗂️ AMajor Alpha Config YAML parsing revamped for better extensibility and preparing v8
236+- 🐛 Squashed some bugs
237+
238+## Important Notes
239+
240+This release introduces a breaking change for Alpha Config users and moves us significantly
241+closer to removing legacy configuration parameters, making the codebase of OAuth2 Proxy more
242+future proof and extensible.
243+
244+From v7.14.0 onward, header injection sources must be explicitly nested. If you
245+previously relied on squashed fields, update to the new structure before upgrading:
246+
247+```yaml
248+# before v7.14.0
249+injectRequestHeaders:
250+- name: X-Forwarded-User
251+ values:
252+ - claim: user
253+- name: X-Custom-Secret-header
254+ values:
255+ - value: my-super-secret
256+
257+# v7.14.0 and later
258+injectRequestHeaders:
259+- name: X-Forwarded-User
260+ values:
261+ - claimSource:
262+ claim: user
263+- name: X-Custom-Secret-header
264+ values:
265+ - secretSource:
266+ value: my-super-secret
267+```
268+
269+Furthermore, Alpha Config now fully supports configuring the `Server` struct using YAML.
270+
271+```yaml
272+// Server represents the configuration for the Proxy HTTP(S) configuration.
273+type Server struct {
274+ // BindAddress is the address on which to serve traffic.
275+ BindAddress string `yaml:"bindAddress,omitempty"`
276+
277+ // SecureBindAddress is the address on which to serve secure traffic.
278+ SecureBindAddress string `yaml:"secureBindAddress,omitempty"`
279+
280+ // TLS contains the information for loading the certificate and key for the
281+ // secure traffic and further configuration for the TLS server.
282+ TLS *TLS `yaml:"tls,omitempty"`
283+}
284+
285+// TLS contains the information for loading a TLS certificate and key
286+// as well as an optional minimal TLS version that is acceptable.
287+type TLS struct {
288+ // Key is the TLS key data to use.
289+ Key *SecretSource `yaml:"key,omitempty"`
290+ // Cert is the TLS certificate data to use.
291+ Cert *SecretSource `yaml:"cert,omitempty"`
292+ // MinVersion is the minimal TLS version that is acceptable.
293+ MinVersion string `yaml:"minVersion,omitempty"`
294+ // CipherSuites is a list of TLS cipher suites that are allowed.
295+ CipherSuites []string `yaml:"cipherSuites,omitempty"`
296+}
297+```
298+
299+More about how to use Alpha Config can be found in the [documentation](https://oauth2-proxy.github.io/oauth2-proxy/configuration/alpha-config#server).
300+
301+We are committed to Semantic Versioning and usually avoid breaking changes without a major version release.
302+Advancing Alpha Config toward its Beta stage required this exception, and even for the Alpha Config we try
303+to keep breaking changes in v7 to a minium. Thank you for understanding the need for this step to prepare
304+the project for future maintainability and future improvements like structured logging.
305+
306+## Breaking Changes
307+
308+- Alpha Config: header injection no longer supports squashed claim/secret sources; they must now be set explicitly (see example above).
309+
310+## Changes since v7.13.0
311+
312+- [#2628](https://github.com/oauth2-proxy/oauth2-proxy/pull/2628) feat(structured config): revamp of yaml parsing using mapstructure decoder and custom decoders (@tuunit)
313+- [#3197](https://github.com/oauth2-proxy/oauth2-proxy/pull/3197) fix: NewRemoteKeySet is not using DefaultHTTPClient (@rsrdesarrollo / @tuunit)
314+- [#3292](https://github.com/oauth2-proxy/oauth2-proxy/pull/3292) chore(deps): upgrade gomod and bump to golang v1.25.5 (@tuunit)
315+- [#3304](https://github.com/oauth2-proxy/oauth2-proxy/pull/3304) fix: added conditional so default is not always set and env vars are honored fixes 3303 (@pixeldrew)
316+- [#3264](https://github.com/oauth2-proxy/oauth2-proxy/pull/3264) fix: more aggressively truncate logged access_token (@MartinNowak / @tuunit)
317+- [#3267](https://github.com/oauth2-proxy/oauth2-proxy/pull/3267) fix: Session refresh handling in OIDC provider (@gysel)
318+- [#3290](https://github.com/oauth2-proxy/oauth2-proxy/pull/3290) fix: WebSocket proxy to respect PassHostHeader setting (@UnsignedLong)
319+
320+# V7.13.0
321+
322+## Release Highlights
323+
324+- 🕵️‍♀️ Vulnerabilities have been addressd
325+ - [CVE-2025-47912](https://nvd.nist.gov/vuln/detail/CVE-2025-47912)
326+ - [CVE-2025-58183](https://nvd.nist.gov/vuln/detail/CVE-2025-58183)
327+ - [CVE-2025-58186](https://nvd.nist.gov/vuln/detail/CVE-2025-58186)
328+ - [CVE-2025-64484](https://nvd.nist.gov/vuln/detail/CVE-2025-64484)
329+- 🐛 Squashed some bugs
330+
331+## Important Notes
332+
333+By default all specified headers will now be normalized, meaning that both capitalization and the use of underscores (_) versus dashes (-) will be ignored when matching headers to be stripped. For example, both `X-Forwarded-For` and `X_Forwarded-for` will now be treated as equivalent and stripped away.
334+
335+Please read our security advisory for CVE-2025-64484: [GHSA-vjrc-mh2v-45x6](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-vjrc-mh2v-45x6)
336+
337+Furthermore, we now use the access_token for validating refreshed sessions in OIDC providers instead of the id_token. This is to align with the [OIDC specification](https://openid.net/specs/openid-connect-core-1_0.html#RefreshTokens) which states that id_tokens are not guaranteed to be issued when using refresh tokens. In future releases we might remove the id_token validation for sessions completely.
338+
339+## Breaking Changes
340+
341+## Changes since v7.12.0
342+
343+- [#3228](https://github.com/oauth2-proxy/oauth2-proxy/pull/3228) fix: use GetSecret() in ticket.go makeCookie to respect cookie-secret-file (@stagswtf)
344+- [#3244](https://github.com/oauth2-proxy/oauth2-proxy/pull/3244) chore(deps): upgrade to latest go1.25.3 (@tuunit)
345+- [#3238](https://github.com/oauth2-proxy/oauth2-proxy/pull/3238) chore: Replace pkg/clock with narrowly targeted stub clocks (@dsymonds)
346+- [#3237](https://github.com/oauth2-proxy/oauth2-proxy/pull/3237) - feat: add option to use organization id for preferred username in Google Provider (@pixeldrew)
347+- [GHSA-vjrc-mh2v-45x6](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-vjrc-mh2v-45x6) fix: request header smuggling by stripping all normalized header variants (@tuunit)
348+- [#1933](https://github.com/oauth2-proxy/oauth2-proxy/pull/1933) fix: validation of refreshed sessions using the access_token in the OIDC provider (@gysel / @tuunit)
349+- [#2841](https://github.com/oauth2-proxy/oauth2-proxy/pull/2841) feat: add allowed_* constraint option to proxy endpoint query string (@jacobalberty)
350+
351+# V7.12.0
352+
353+## Release Highlights
354+
355+- 🕵️‍♀️ Vulnerabilities have been addressed
356+ - [CVE-2025-47907](https://pkg.go.dev/vuln/GO-2025-3849)
357+- 🦸 Support for Cidaas IDP
358+- 🐛 Squashed some bugs
359+
360+
361+## Important Notes
362+
363+## Breaking Changes
364+
365+## Changes since v7.11.0
366+
367+- [#2273](https://github.com/oauth2-proxy/oauth2-proxy/pull/2273) feat: add Cidaas provider (@Bibob7, @Teko012)
368+- [#3166](https://github.com/oauth2-proxy/oauth2-proxy/pull/3166) chore(dep): upgrade to latest golang 1.24.6 (@tuunit)
369+- [#3156](https://github.com/oauth2-proxy/oauth2-proxy/pull/3156) feat: allow disable-keep-alives configuration for upstream (@jet-go)
370+- [#3150](https://github.com/oauth2-proxy/oauth2-proxy/pull/3150) fix: Gitea team membership (@MagicRB, @tuunit)
371+
372+# V7.11.0
373+
374+## Release Highlights
375+
376+- 🏢 Support for SourceHut (sr.ht) provider
377+- 🔍️ Support for more fine-grained control over the google admin-sdk scopes and optional google groups
378+- 🐛 Squashed some bugs
379+
380+
381+## Important Notes
382+
383+Firstly, fixed critical vulnerability where `skip_auth_routes` regex patterns matched against the full request URI (path + query parameters) instead of just the path, allowing authentication bypass attacks.
384+
385+Secondly, fixed double-escaping of `$` in regexes for Alpha Config upstreams path and rewriteTargets:
386+
387+```yaml
388+# Before
389+upstreams:
390+ - id: web
391+ path: ^/(.*)$$
392+ rewriteTarget: /$$1
393+
394+# After
395+upstreams:
396+ - id: web
397+ path: ^/(.*)$
398+ rewriteTarget: /$1
399+```
400+
401+
402+## Breaking Changes
403+
404+If your configuration relies on matching query parameters in `skip_auth_routes` patterns, you must update your regex patterns to match paths only. Review all `skip_auth_routes` entries for potential impact.
405+
406+**Example of affected configuration:**
407+```yaml
408+# This pattern previously matched both:
409+# - /api/foo/status (intended)
410+# - /api/private/sensitive?path=/status (bypass - now fixed)
411+skip_auth_routes: ["^/api/.*/status"]
412+```
413+
414+For detailed information, migration guidance, and security implications, see the [security advisory](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-7rh7-c77v-6434).
415+
416+## Changes since v7.10.0
417+
418+- [#2615](https://github.com/oauth2-proxy/oauth2-proxy/pull/2615) feat(cookies): add option to set a limit on the number of per-request CSRF cookies oauth2-proxy sets (@bh-tt)
419+- [#2605](https://github.com/oauth2-proxy/oauth2-proxy/pull/2605) fix: show login page on broken cookie (@Primexz)
420+- [#2743](https://github.com/oauth2-proxy/oauth2-proxy/pull/2743) feat: allow use more possible google admin-sdk api scopes (@BobDu)
421+- [#2359](https://github.com/oauth2-proxy/oauth2-proxy/pull/2359) feat: add SourceHut (sr.ht) provider(@bitfehler)
422+- [#2524](https://github.com/oauth2-proxy/oauth2-proxy/pull/2524) fix: regex substitution for $ signs in upstream path handling before running envsubst (@dashkan / @tuunit)
423+- [#3104](https://github.com/oauth2-proxy/oauth2-proxy/pull/3104) feat(cookie): add feature support for cookie-secret-file (@sandy2008)
424+- [#3055](https://github.com/oauth2-proxy/oauth2-proxy/pull/3055) feat: support non-default authorization request response mode also for OIDC providers (@stieler-it)
425+- [#3138](https://github.com/oauth2-proxy/oauth2-proxy/pull/3138) feat: make google_groups argument optional when using google provider (@sourava01)
426+- [#3093](https://github.com/oauth2-proxy/oauth2-proxy/pull/3093) feat: differentiate between "no available key" and error for redis sessions (@nobletrout)
427+- [GHSA-7rh7-c77v-6434](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-7rh7-c77v-6434) fix: skip_auth_routes bypass through query parameter inclusion
428+
429+
430+# V7.10.0
431+
432+## Release Highlights
433+- 🏢 Support for multiple orgs using the GitHub / Gitea provider
434+- 🔵 Golang version upgrade to v1.24.5
435+- 🕵️‍♀️ Vulnerabilities have been addressed
436+ - [CVE-2025-4673](https://access.redhat.com/security/cve/CVE-2025-4673)
437+ - [CVE-2025-22872](https://access.redhat.com/security/cve/CVE-2025-22872)
438+ - [CVE-2025-09130](https://nvd.nist.gov/vuln/detail/CVE-2025-09130)
439+ - [CVE-2025-22871](https://access.redhat.com/security/cve/CVE-2025-22871)
440+- 🐛 Squashed some bugs
441+
442+## Important Notes
443+
444+## Breaking Changes
445+
446+## Changes since v7.9.0
447+
448+- [#3072](https://github.com/oauth2-proxy/oauth2-proxy/pull/3072) feat: support for multiple github orgs #3072 (@daniel-mersch)
449+- [#3116](https://github.com/oauth2-proxy/oauth2-proxy/pull/3116) feat: bump to go1.24.5 and full dependency update (@wardviaene / @dolmen)
450+- [#3097](https://github.com/oauth2-proxy/oauth2-proxy/pull/3097) chore(deps): update alpine base image to v3.22.0
451+- [#3101](https://github.com/oauth2-proxy/oauth2-proxy/pull/3101) fix: return error for empty Redis URL list (@dgivens)
452+
453+# V7.9.0
454+
455+## Release Highlights
456+- 📨 OAuth 2.0 Multiple Response Type Encoding
457+- 📦️ Support for JWT encoded profile claims
458+- 🔵 Golang version upgrade to v1.23.8
459+- 🕵️‍♀️ Vulnerabilities have been addressed
460+ - [CVE-2025-22871](https://github.com/advisories/GHSA-g9pc-8g42-g6vq)
461+- 🐛 Squashed some bugs
462+
463+## Important Notes
464+
465+## Breaking Changes
466+
467+## Changes since v7.8.2
468+
469+- [#3031](https://github.com/oauth2-proxy/oauth2-proxy/pull/3031) Fixes Refresh Token bug with Entra ID and Workload Identity (#3027)[https://github.com/oauth2-proxy/oauth2-proxy/issues/3028] by using client assertion when redeeming the token (@richard87)
470+- [#3001](https://github.com/oauth2-proxy/oauth2-proxy/pull/3001) Allow to set non-default authorization request response mode (@stieler-it)
471+- [#3041](https://github.com/oauth2-proxy/oauth2-proxy/pull/3041) chore(deps): upgrade to latest golang v1.23.x release (@TheImplementer)
472+- [#1916](https://github.com/oauth2-proxy/oauth2-proxy/pull/1916) fix: role extraction from access token in keycloak oidc (@Elektordi / @tuunit)
473+- [#3014](https://github.com/oauth2-proxy/oauth2-proxy/pull/3014) feat: ability to parse JWT encoded profile claims (@ikarius)
474+
475+# V7.8.2
476+
477+## Release Highlights
478+- 🐛 Cookie Expiration bug has been squashed
479+- 🔵 Golang version upgrade to v1.23.7
480+- 🕵️‍♀️ Vulnerabilities have been addressed
481+ - CVE-2025-30204
482+ - CVE-2025-27144
483+ - CVE-2024-45336
484+ - CVE-2025-22866
485+ - CVE-2025-22870
486+ - CVE-2024-45341
487+ - CVE-2025-29923
488+ - CVE-2025-22866
489+ - CVE-2024-34156
490+
491+## Important Notes
492+
493+## Breaking Changes
494+
495+## Changes since v7.8.1
496+
497+- [#2918](https://github.com/oauth2-proxy/oauth2-proxy/issues/2918) feat: add --bearer-token-login-fallback (@carillonator)
498+- [#2927](https://github.com/oauth2-proxy/oauth2-proxy/pull/2927) chore(deps/build): bump golang to 1.23 and use go.mod as single point of truth for all build files (@tuunit)
499+- [#2697](https://github.com/oauth2-proxy/oauth2-proxy/pull/2697) Use `Max-Age` instead of `Expires` for cookie expiration (@matpen-wi)
500+- [#2969](https://github.com/oauth2-proxy/oauth2-proxy/pull/2969) Update golang.org/x/oauth2 to v0.27.0 to address CVE-2025-22868 (@dsymonds)
501+- [#2977](https://github.com/oauth2-proxy/oauth2-proxy/pull/2977) Update golang.org/x/net to v0.36.0 to address CVE-2025-22870 (@dsymonds)
502+- [#2982](https://github.com/oauth2-proxy/oauth2-proxy/pull/2982) chore(deps): remove go:generate tool from go.mod (@dolmen)
503+- [#3011](https://github.com/oauth2-proxy/oauth2-proxy/pull/3011) chore(deps): update golang dependencies and pin to latest golang v1.23.x release (@tuunit)
504+- [#2967](https://github.com/oauth2-proxy/oauth2-proxy/pull/2967) Update HashNonce to use crypto/sha256 (@egibs)
505+
506+# V7.8.1
507+
508+## Release Highlights
509+
510+- 🐛 Two bugs have been squashed
511+
512+## Important Notes
513+
514+## Breaking Changes
515+
516+## Changes since v7.8.0
517+
518+- [#2887](https://github.com/oauth2-proxy/oauth2-proxy/issues/2887) fix: jwt regex validation error during skip-jwt-bearer-tokens flow
519+- [#2920](https://github.com/oauth2-proxy/oauth2-proxy/pull/2920) fix: missing oauth2-proxy version for docker builds
520+
521+# V7.8.0
522+
523+## Release Highlights
524+
525+- ☁️ Introducing support for Microsoft Entra ID
526+ - Including Support for Azure Workload Identity as well
527+ - Including full e2e testing using Azure Credits from MS sponsoring
528+ - Deprecated old Azure AD provider
529+- 🪪 Static local JWKS file support
530+- Support for systemd sockets
531+- 🐛 Several bugs have been squashed
532+- 🕵️‍♀️ Vulnerabilities have been addressed
533+ - CVE-2024-45338
534+
535+## Important Notes
536+
537+## Breaking Changes
538+
539+## Changes since v7.7.1
540+
541+- [#2390](https://github.com/oauth2-proxy/oauth2-proxy/pull/2390) feat: add Microsoft Entra ID provider (@jjlakis / @tuunit)
542+- [#2902](https://github.com/oauth2-proxy/oauth2-proxy/pull/2902) feat(entra): add Workload Identity support for Entra ID (@jjlakis)
543+- [#2800](https://github.com/oauth2-proxy/oauth2-proxy/pull/2800) doc: add some opencontainer labels to docker image (@halkeye)
544+- [#2755](https://github.com/oauth2-proxy/oauth2-proxy/pull/2755) feat: add X-Envoy-External-Address as supported header (@bjencks)
545+- [#1985](https://github.com/oauth2-proxy/oauth2-proxy/pull/1985) feat: add support for systemd socket (@isodude)
546+- [#2916](https://github.com/oauth2-proxy/oauth2-proxy/pull/2916) fix: systemd socket support build handling for windows (@tuunit)
547+- [#2300](https://github.com/oauth2-proxy/oauth2-proxy/pull/2300) fix: add fix for websocket path rewrite (@rekup)
548+- [#2821](https://github.com/oauth2-proxy/oauth2-proxy/pull/2821) feat: add CF-Connecting-IP as supported real ip header (@ondrejsika)
549+- [#2620](https://github.com/oauth2-proxy/oauth2-proxy/pull/2620) fix: update code_verifier to use recommended method (@vishvananda)
550+- [#2376](https://github.com/oauth2-proxy/oauth2-proxy/pull/2376) feat: static public keys file support for oidc provider (@axel7083 / @jjlakis)
551+- [#2392](https://github.com/oauth2-proxy/oauth2-proxy/pull/2392) chore: extend test cases for oidc provider and documentation regarding implicit setting of the groups scope when no scope was specified in the config (@jjlakis / @tuunit)
552+
553+# V7.7.1
554+
555+## Release Highlights
556+
557+- 🐛 Several bugs have been squashed
558+
559+## Important Notes
560+
561+## Breaking Changes
562+
563+## Changes since v7.7.0
564+
565+- [#2803](https://github.com/oauth2-proxy/oauth2-proxy/pull/2803) fix: self signed certificate handling in v7.7.0 (@tuunit)
566+- [#2619](https://github.com/oauth2-proxy/oauth2-proxy/pull/2619) fix: unable to use hyphen in JSON path for oidc-groups-claim option (@rd-danny-fleer)
567+- [#2311](https://github.com/oauth2-proxy/oauth2-proxy/pull/2311) fix: runtime error: index out of range (0) with length 0 (@miguelborges99 / @tuunit)
568+
569+# V7.7.0
570+
571+## Release Highlights
572+
573+- 🌐 Custom user agent "oauth2-proxy/<version>"
574+- 💾 Added s390x architecture support
575+- 🕵️‍♀️ Vulnerabilities have been addressed
576+ - CVE-2024-24786
577+ - CVE-2024-24791
578+ - CVE-2024-24790
579+ - CVE-2024-24784
580+- 📖 Improved docs
581+
582+## Important Notes
583+- Remove support of arm/v6 for distroless image runtime. Alpine tags still support arm/v6.
584+
585+## Breaking Changes
586+
9587## Changes since v7.6.0
10588
11589- [#2539](https://github.com/oauth2-proxy/oauth2-proxy/pull/2539) pkg/http: Fix leaky test (@isodude)
12590- [#4917](https://github.com/oauth2-proxy/oauth2-proxy/pull/4917) Upgraded all modules to the latest version (@pierluigilenoci)
13591- [#2570](https://github.com/oauth2-proxy/oauth2-proxy/pull/2570) Set default user agent to oauth2-proxy/$version (from default Golang one)
592+- [#2674](https://github.com/oauth2-proxy/oauth2-proxy/pull/2674) docs: additional notes about available claims for HeaderValue (@vegetablest)
593+- [#2459](https://github.com/oauth2-proxy/oauth2-proxy/pull/2459) chore(deps): Updated to ginkgo v2 (@kvanzuijlen, @tuunit)
594+- [#2112](https://github.com/oauth2-proxy/oauth2-proxy/pull/2112) docs: update list of providers which support refresh tokens (@mikefab-msf)
595+- [#2734](https://github.com/oauth2-proxy/oauth2-proxy/pull/2734) Added s390x architecture option support (@priby05)
596+- [#2589](https://github.com/oauth2-proxy/oauth2-proxy/pull/2589) Added support for regex path matching and rewriting when using a static `file:` upstream (@ianroberts)
597+- [#2790](https://github.com/oauth2-proxy/oauth2-proxy/pull/2790) chore(deps): update all golang dependencies (@tuunit)
598+- [#2607](https://github.com/oauth2-proxy/oauth2-proxy/pull/2607) fix(csrf): fix possible infinite loop (@Primexz)
14599
15600# V7.6.0
16601
CODE_OF_CONDUCT.md+81−103
@@ -1,134 +1,112 @@
1−# Contributor Covenant Code of Conduct
1+## CNCF Community Code of Conduct v1.3
2+
3+Other languages available:
4+- [Arabic/العربية](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/ar.md)
5+- [Bengali/বাংলা](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/bn.md)
6+- [Bulgarian/Български](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/bg.md)
7+- [Chinese/中文](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/zh.md)
8+- [Czech/Česky](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/cs.md)
9+- [Farsi/فارسی](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/fa.md)
10+- [French/Français](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/fr.md)
11+- [German/Deutsch](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/de.md)
12+- [Hebrew/עברית](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/he.md)
13+- [Hindi/हिन्दी](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/hi.md)
14+- [Hungarian/Magyar](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/hu.md)
15+- [Indonesian/Bahasa Indonesia](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/id.md)
16+- [Italian/Italiano](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/it.md)
17+- [Japanese/日本語](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/ja.md)
18+- [Korean/한국어](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/ko.md)
19+- [Polish/Polski](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/pl.md)
20+- [Portuguese/Português](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/pt.md)
21+- [Russian/Русский](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/ru.md)
22+- [Spanish/Español](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/es.md)
23+- [Turkish/Türkçe](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/tr.md)
24+- [Ukrainian/Українська](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/uk.md)
25+- [Vietnamese/Tiếng Việt](https://github.com/cncf/foundation/blob/main/code-of-conduct-languages/vi.md)
26+
27+### Community Code of Conduct
28+
29+As contributors, maintainers, and participants in the CNCF community, and in the interest of fostering
30+an open and welcoming community, we pledge to respect all people who participate or contribute
31+through reporting issues, posting feature requests, updating documentation,
32+submitting pull requests or patches, attending conferences or events, or engaging in other community or project activities.
33+
34+We are committed to making participation in the CNCF community a harassment-free experience for everyone, regardless of age, body size, caste, disability, ethnicity, level of experience, family status, gender, gender identity and expression, marital status, military or veteran status, nationality, personal appearance, race, religion, sexual orientation, socioeconomic status, tribe, or any other dimension of diversity.
235
3−## Our Pledge
36+## Scope
37+
38+This code of conduct applies:
39+* within project and community spaces,
40+* in other spaces when an individual CNCF community participant's words or actions are directed at or are about a CNCF project, the CNCF community, or another CNCF community participant in the context of a CNCF activity.
441
5−We as members, contributors, and leaders pledge to make participation in our
6−community a harassment-free experience for everyone, regardless of age, body
7−size, visible or invisible disability, ethnicity, sex characteristics, gender
8−identity and expression, level of experience, education, socio-economic status,
9−nationality, personal appearance, race, caste, color, religion, or sexual
10−identity and orientation.
42+### CNCF Events
1143
12−We pledge to act and interact in ways that contribute to an open, welcoming,
13−diverse, inclusive, and healthy community.
44+CNCF events that are produced by the Linux Foundation with professional events staff are governed by the Linux Foundation [Events Code of Conduct](https://events.linuxfoundation.org/code-of-conduct/) available on the event page. This is designed to be used in conjunction with the CNCF Code of Conduct.
1445
1546## Our Standards
1647
17−Examples of behavior that contributes to a positive environment for our
18−community include:
48+The CNCF Community is open, inclusive and respectful. Every member of our community has the right to have their identity respected.
49+
50+Examples of behavior that contributes to a positive environment include but are not limited to:
1951
2052* Demonstrating empathy and kindness toward other people
2153* Being respectful of differing opinions, viewpoints, and experiences
2254* Giving and gracefully accepting constructive feedback
2355* Accepting responsibility and apologizing to those affected by our mistakes,
2456 and learning from the experience
25−* Focusing on what is best not just for us as individuals, but for the overall
26− community
57+* Focusing on what is best not just for us as individuals, but for the
58+ overall community
59+* Using welcoming and inclusive language
2760
28−Examples of unacceptable behavior include:
2961
30−* The use of sexualized language or imagery, and sexual attention or advances of
31− any kind
62+Examples of unacceptable behavior include but are not limited to:
63+
64+* The use of sexualized language or imagery
3265* Trolling, insulting or derogatory comments, and personal or political attacks
33−* Public or private harassment
34−* Publishing others' private information, such as a physical or email address,
35− without their explicit permission
66+* Public or private harassment in any form
67+* Publishing others' private information, such as a physical or email
68+ address, without their explicit permission
69+* Violence, threatening violence, or encouraging others to engage in violent behavior
70+* Stalking or following someone without their consent
71+* Unwelcome physical contact
72+* Unwelcome sexual or romantic attention or advances
73+* Using CNCF projects or community spaces for political campaigning or promotion of political causes
74+ that are unrelated to the advancement of cloud native technology. To clarify, this policy does not restrict individuals' personal attire, including attire that expresses personal beliefs or aspects of identity.
3675* Other conduct which could reasonably be considered inappropriate in a
3776 professional setting
3877
39−## Enforcement Responsibilities
40−
41−Community leaders are responsible for clarifying and enforcing our standards of
42−acceptable behavior and will take appropriate and fair corrective action in
43−response to any behavior that they deem inappropriate, threatening, offensive,
44−or harmful.
45−
46−Community leaders have the right and responsibility to remove, edit, or reject
47−comments, commits, code, wiki edits, issues, and other contributions that are
48−not aligned to this Code of Conduct, and will communicate reasons for moderation
49−decisions when appropriate.
50−
51−## Scope
52−
53−This Code of Conduct applies within all community spaces, and also applies when
54−an individual is officially representing the community in public spaces.
55−Examples of representing our community include using an official email address,
56−posting via an official social media account, or acting as an appointed
57−representative at an online or offline event.
58−
59−## Enforcement
78+The following behaviors are also prohibited:
79+* Providing knowingly false or misleading information in connection with a Code of Conduct investigation or otherwise intentionally tampering with an investigation.
80+* Retaliating against a person because they reported an incident or provided information about an incident as a witness.
6081
61−Instances of abusive, harassing, or otherwise unacceptable behavior may be
62−reported to the community leaders responsible for enforcement at
63−https://gophers.slack.com/messages/CM2RSS25N or directly contacting one of the
64−maintainers from the MAINTAINERS file.
65−All complaints will be reviewed and investigated promptly and fairly.
82+Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct.
83+By adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently applying these principles to every aspect
84+of managing a CNCF project.
85+Project maintainers who do not follow or enforce the Code of Conduct may be temporarily or permanently removed from the project team.
6686
67−All community leaders are obligated to respect the privacy and security of the
68−reporter of any incident.
87+## Reporting
6988
70−## Enforcement Guidelines
89+For incidents occurring in the Kubernetes community, contact the [Kubernetes Code of Conduct Committee](https://git.k8s.io/community/committee-code-of-conduct) via <conduct@kubernetes.io>. You can expect a response within three business days.
7190
72−Community leaders will follow these Community Impact Guidelines in determining
73−the consequences for any action they deem in violation of this Code of Conduct:
91+For other projects, or for incidents that are project-agnostic or impact multiple CNCF projects, please contact the [CNCF Code of Conduct Committee](https://www.cncf.io/conduct/committee/) via <conduct@cncf.io>. Alternatively, you can contact any of the individual members of the [CNCF Code of Conduct Committee](https://www.cncf.io/conduct/committee/) to submit your report. For more detailed instructions on how to submit a report, including how to submit a report anonymously, please see our [Incident Resolution Procedures](https://github.com/cncf/foundation/blob/main/code-of-conduct/coc-incident-resolution-procedures.md). You can expect a response within three business days.
7492
75−### 1. Correction
93+For incidents occurring at CNCF event that is produced by the Linux Foundation, please contact <eventconduct@cncf.io>.
7694
77−**Community Impact**: Use of inappropriate language or other behavior deemed
78−unprofessional or unwelcome in the community.
95+## Frequently asked questions
96+For more information about this Code of Conduct, please see the [CNCF Code of Conduct Frequently Asked Questions](https://www.cncf.io/conduct/faq/).
7997
80−**Consequence**: A private, written warning from community leaders, providing
81−clarity around the nature of the violation and an explanation of why the
82−behavior was inappropriate. A public apology may be requested.
83−
84−### 2. Warning
85−
86−**Community Impact**: A violation through a single incident or series of
87−actions.
88−
89−**Consequence**: A warning with consequences for continued behavior. No
90−interaction with the people involved, including unsolicited interaction with
91−those enforcing the Code of Conduct, for a specified period of time. This
92−includes avoiding interactions in community spaces as well as external channels
93−like social media. Violating these terms may lead to a temporary or permanent
94−ban.
95−
96−### 3. Temporary Ban
97−
98−**Community Impact**: A serious violation of community standards, including
99−sustained inappropriate behavior.
100−
101−**Consequence**: A temporary ban from any sort of interaction or public
102−communication with the community for a specified period of time. No public or
103−private interaction with the people involved, including unsolicited interaction
104−with those enforcing the Code of Conduct, is allowed during this period.
105−Violating these terms may lead to a permanent ban.
106−
107−### 4. Permanent Ban
108−
109−**Community Impact**: Demonstrating a pattern of violation of community
110−standards, including sustained inappropriate behavior, harassment of an
111−individual, or aggression toward or disparagement of classes of individuals.
112−
113−**Consequence**: A permanent ban from any sort of public interaction within the
114−community.
98+## Enforcement
11599
116−## Attribution
100+Upon review and investigation of a reported incident, the CoC response team that has jurisdiction will determine what action is appropriate based on this Code of Conduct and its related documentation.
117101
118−This Code of Conduct is adapted from the [Contributor Covenant][homepage],
119−version 2.1, available at
120−[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
102+For information about which Code of Conduct incidents are handled by project leadership, which incidents are handled by the CNCF Code of Conduct Committee, and which incidents are handled by the Linux Foundation (including its events team), see our [Jurisdiction Policy](https://github.com/cncf/foundation/blob/main/code-of-conduct/coc-committee-jurisdiction-policy.md).
121103
122−Community Impact Guidelines were inspired by
123−[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
104+## Amendments
124105
125−For answers to common questions about this code of conduct, see the FAQ at
126−[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
127−[https://www.contributor-covenant.org/translations][translations].
106+Consistent with the CNCF Charter, any substantive changes to this Code of Conduct must be approved by the Technical Oversight Committee.
128107
129−[homepage]: https://www.contributor-covenant.org
130−[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
131−[Mozilla CoC]: https://github.com/mozilla/diversity
132−[FAQ]: https://www.contributor-covenant.org/faq
133−[translations]: https://www.contributor-covenant.org/translations
108+## Acknowledgements
134109
110+This Code of Conduct is adapted from the Contributor Covenant
111+(http://contributor-covenant.org), version 2.0 available at
112+http://contributor-covenant.org/version/2/0/code_of_conduct/
DCO.mdnew file+34
@@ -0,0 +1,34 @@
1+Developer Certificate of Origin
2+Version 1.1
3+
4+Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
5+
6+Everyone is permitted to copy and distribute verbatim copies of this
7+license document, but changing it is not allowed.
8+
9+
10+Developer's Certificate of Origin 1.1
11+
12+By making a contribution to this project, I certify that:
13+
14+(a) The contribution was created in whole or in part by me and I
15+ have the right to submit it under the open source license
16+ indicated in the file; or
17+
18+(b) The contribution is based upon previous work that, to the best
19+ of my knowledge, is covered under an appropriate open source
20+ license and I have the right under that license to submit that
21+ work with modifications, whether created in whole or in part
22+ by me, under the same open source license (unless I am
23+ permitted to submit under a different license), as indicated
24+ in the file; or
25+
26+(c) The contribution was provided directly to me by some other
27+ person who certified (a), (b) or (c) and I have not modified
28+ it.
29+
30+(d) I understand and agree that this project and the contribution
31+ are public and that a record of the contribution (including all
32+ personal information I submit with it, including my sign-off) is
33+ maintained indefinitely and may be redistributed consistent with
34+ this project or the open source license(s) involved.
Dockerfile+30−7
@@ -1,11 +1,18 @@
1−# This ARG has to be at the top, otherwise the docker daemon does not known what to do with FROM ${RUNTIME_IMAGE}
2−ARG RUNTIME_IMAGE=gcr.io/distroless/static:nonroot
1+# The image ARGs have to be at the top, otherwise the docker daemon cannot validate
2+# the FROM statements and overall Dockerfile
3+#
4+# Argument for setting the build image
5+ARG BUILD_IMAGE=placeholder
6+# Argument for setting the runtime image
7+ARG RUNTIME_IMAGE=placeholder
8+# Argument for setting the oauth2-proxy build version
9+ARG VERSION
310
411# All builds should be done using the platform native to the build node to allow
512# cache sharing of the go mod download step.
613# Go cross compilation is also faster than emulation the go compilation across
714# multiple platforms.
8−FROM --platform=${BUILDPLATFORM} docker.io/library/golang:1.22-bookworm AS builder
15+FROM --platform=${BUILDPLATFORM} ${BUILD_IMAGE} AS builder
916
1017# Copy sources
1118WORKDIR $GOPATH/src/github.com/oauth2-proxy/oauth2-proxy
@@ -17,12 +24,14 @@ RUN go mod download
1724# Now pull in our code
1825COPY . .
1926
20−# Arguments go here so that the previous steps can be cached if no external
21−# sources have changed.
22−ARG VERSION
27+# Arguments go here so that the previous steps can be cached if no external sources
28+# have changed. These arguments are automatically set by the docker engine.
2329ARG TARGETPLATFORM
2430ARG BUILDPLATFORM
2531
32+# Reload version argument
33+ARG VERSION
34+
2635# Build binary and make sure there is at least an empty key file.
2736# This is useful for GCP App Engine custom runtime builds, because
2837# you cannot use multiline variables in their app.yaml, so you have to
@@ -33,19 +42,33 @@ ARG BUILDPLATFORM
3342# automatically set by the docker engine.
3443RUN case ${TARGETPLATFORM} in \
3544 "linux/amd64") GOARCH=amd64 ;; \
36− # arm64 and arm64v8 are equivilant in go and do not require a goarm
45+ # arm64 and arm64v8 are equivalent in go and do not require a goarm
3746 # https://github.com/golang/go/wiki/GoArm
3847 "linux/arm64" | "linux/arm/v8") GOARCH=arm64 ;; \
3948 "linux/ppc64le") GOARCH=ppc64le ;; \
49+ "linux/s390x") GOARCH=s390x ;; \
4050 "linux/arm/v6") GOARCH=arm GOARM=6 ;; \
4151 "linux/arm/v7") GOARCH=arm GOARM=7 ;; \
4252 esac && \
4353 printf "Building OAuth2 Proxy for arch ${GOARCH}\n" && \
4454 GOARCH=${GOARCH} VERSION=${VERSION} make build && touch jwt_signing_key.pem
4555
56+# Reload runtime image
57+ARG RUNTIME_IMAGE
4658# Copy binary to runtime image
4759FROM ${RUNTIME_IMAGE}
60+# Reload version
61+ARG VERSION
62+
4863COPY --from=builder /go/src/github.com/oauth2-proxy/oauth2-proxy/oauth2-proxy /bin/oauth2-proxy
4964COPY --from=builder /go/src/github.com/oauth2-proxy/oauth2-proxy/jwt_signing_key.pem /etc/ssl/private/jwt_signing_key.pem
5065
66+LABEL org.opencontainers.image.licenses=MIT \
67+ org.opencontainers.image.description="A reverse proxy that provides authentication with Google, Azure, OpenID Connect and many more identity providers." \
68+ org.opencontainers.image.documentation=https://oauth2-proxy.github.io/oauth2-proxy/ \
69+ org.opencontainers.image.source=https://github.com/oauth2-proxy/oauth2-proxy \
70+ org.opencontainers.image.url=https://quay.io/oauth2-proxy/oauth2-proxy \
71+ org.opencontainers.image.title=oauth2-proxy \
72+ org.opencontainers.image.version=${VERSION}
73+
5174ENTRYPOINT ["/bin/oauth2-proxy"]
MAINTAINERS+2−4
@@ -1,4 +1,2 @@
1−Joel Speed <joel.speed@hotmail.co.uk> (@JoelSpeed)
2−Nick Meves <gills-vector-0p@icloud.com> (@NickMeves)
3−Jan Larwig <jan@larwig.com> (@tuunit)
4−Koen van Zuijlen <kvz.public@gmail.com> (@kvanzuijlen)
1+
2+Moved to https://github.com/oauth2-proxy/oauth2-proxy/blob/master/MAINTAINERS.md
MAINTAINERS.mdnew file+33
@@ -0,0 +1,33 @@
1+# Maintainers
2+
3+The table below lists all current maintainers for the oauth2-proxy as defined
4+by our [project governance](GOVERNANCE.md).
5+
6+| Name | GitHub Handle | Domains of reponsibility | Email Alias | Affiliation |
7+| ---------------- | ------------------------------------------------------ | ------------------------ | -------------------------- | ----------- |
8+| Joel Speed | [@JoelSpeed](https://github.com/joelspeed) | Governance, Core | joel@oauth2-proxy.dev | Red Hat |
9+| Jan Larwig | [@tuunit](https://github.com/tuunit) | Governance, Core | jan@oauth2-proxy.dev | STACKIT |
10+| JJ Łakis | [@jjlakis](https://github.com/jjlakis) | Provider | jj@oauth2-proxy.dev | - |
11+| Koen van Zuijlen | [@kvanzuijlen](https://github.com/kvanzuijlen) | CI | koen@oauth2-proxy.dev | - |
12+| Pierluigi Lenoci | [@pierluigilenoci](https://github.com/pierluigilenoci) | Helm | pierluigi@oauth2-proxy.dev | SAP |
13+
14+## Emeritus Maintainers
15+
16+We would like to highlight that this project does have prior maintainers and
17+core contributors that, if they so wished, could (and should) be granted the
18+status of emeritus maintainers.
19+
20+| Name | GitHub Handle |
21+| ------------- | ------------------------------------------------------ |
22+| Nick Meves | [@NickMeves](https://github.com/NickMeves) |
23+| Braunson | [@braunsonm](https://github.com/braunsonm) |
24+| Henry Jenkins | [@steakunderscore](https://github.com/steakunderscore) |
25+
26+
27+## Security Response Team and GitHub Organization Owners
28+
29+The following maintainers are members of the security response team and owners
30+of the GitHub organization.
31+
32+- Joel Speed
33+- Jan Larwig
Makefile+106−58
@@ -1,5 +1,32 @@
1+#!/usr/bin/env bash
2+
3+#
4+# Makefile with some common workflow for dev, build and test
5+#
6+
7+##@ General
8+
9+# The help target prints out all targets with their descriptions organized
10+# beneath their categories. The categories are represented by '##@' and the
11+# target descriptions by '##'. The awk command is responsible for reading the
12+# entire set of makefiles included in this invocation, looking for lines of the
13+# file as xyz: ## something, and then pretty-format the target and help. Then,
14+# if there's a line with ##@ something, that gets pretty-printed as a category.
15+# More info on the usage of ANSI control characters for terminal formatting:
16+# https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_parameters
17+# More info on the awk command:
18+# http://linuxcommand.org/lc3_adv_awk.php
19+
20+# The following help command is Licensed under the Apache License, Version 2.0 (the "License")
21+# Copyright 2023 The Kubernetes Authors.
22+.PHONY: help
23+help: ## Display this help
24+ @awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n"} /^[a-zA-Z_0-9-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST)
25+
26+
127GO ?= go
2−GOLANGCILINT ?= golangci-lint
28+# renovate: datasource=github-tags depName=golangci/golangci-lint
29+GOLANGCILINT_VERSION ?= v2.11.4
330
431BINARY := oauth2-proxy
532VERSION ?= $(shell git describe --always --dirty --tags 2>/dev/null || echo "undefined")
@@ -10,115 +37,136 @@ REPOSITORY ?= oauth2-proxy
1037DATE := $(shell date +"%Y%m%d")
1138.NOTPARALLEL:
1239
13−GO_MAJOR_VERSION = $(shell $(GO) version | cut -c 14- | cut -d' ' -f1 | cut -d'.' -f1)
14−GO_MINOR_VERSION = $(shell $(GO) version | cut -c 14- | cut -d' ' -f1 | cut -d'.' -f2)
15−MINIMUM_SUPPORTED_GO_MAJOR_VERSION = 1
16−MINIMUM_SUPPORTED_GO_MINOR_VERSION = 20
17−GO_VERSION_VALIDATION_ERR_MSG = Golang version is not supported, please update to at least $(MINIMUM_SUPPORTED_GO_MAJOR_VERSION).$(MINIMUM_SUPPORTED_GO_MINOR_VERSION)
40+# The go version in go.mod used for the Docker build toolchain, without the patch
41+GO_MOD_VERSION_MINOR := $(shell $(GO) list -f '{{printf "%.4s" .Module.GoVersion}}' )
42+
43+# From go1.21 go will transparently download the toolchain declared in go.mod. https://go.dev/doc/toolchain
44+# We don't need to keep this message updated: the important info is in go.mod.
45+GO_VERSION_VALIDATION_ERR_MSG = Golang version is not supported, please update to at least go1.21
1846
1947ifeq ($(COVER),true)
2048TESTCOVER ?= -coverprofile c.out
2149endif
2250
23−.PHONY: all
24−all: lint $(BINARY)
25−
26−.PHONY: clean
27−clean:
28− -rm -rf release
29− -rm -f $(BINARY)
30−
31−.PHONY: distclean
32−distclean: clean
33− rm -rf vendor
34−
35−.PHONY: lint
36−lint: validate-go-version
37− GO111MODULE=on $(GOLANGCILINT) run
51+##@ Build
3852
3953.PHONY: build
40−build: validate-go-version clean $(BINARY)
54+build: validate-go-version clean $(BINARY) ## Build and create oauth2-proxy binary from current source code
4155
4256$(BINARY):
4357 CGO_ENABLED=0 $(GO) build -a -installsuffix cgo -ldflags="-X github.com/oauth2-proxy/oauth2-proxy/v7/pkg/version.VERSION=${VERSION}" -o $@ github.com/oauth2-proxy/oauth2-proxy/v7
4458
45−DOCKER_BUILD_PLATFORM ?= linux/amd64,linux/arm64,linux/ppc64le,linux/arm/v7
59+DOCKER_BUILDX_COMMON_ARGS ?= --build-arg BUILD_IMAGE=docker.io/library/golang:$(GO_MOD_VERSION_MINOR)-bookworm --build-arg VERSION=$(VERSION)
60+
61+DOCKER_BUILD_PLATFORM ?= linux/amd64,linux/arm64,linux/ppc64le,linux/arm/v7,linux/s390x
4662DOCKER_BUILD_RUNTIME_IMAGE ?= gcr.io/distroless/static:nonroot
47−DOCKER_BUILDX_ARGS ?= --build-arg RUNTIME_IMAGE=${DOCKER_BUILD_RUNTIME_IMAGE} --build-arg VERSION=${VERSION}
63+DOCKER_BUILDX_ARGS ?= --build-arg RUNTIME_IMAGE=${DOCKER_BUILD_RUNTIME_IMAGE} ${DOCKER_BUILDX_COMMON_ARGS}
4864DOCKER_BUILDX := docker buildx build ${DOCKER_BUILDX_ARGS} --pull
4965DOCKER_BUILDX_X_PLATFORM := $(DOCKER_BUILDX) --platform ${DOCKER_BUILD_PLATFORM}
5066DOCKER_BUILDX_PUSH := $(DOCKER_BUILDX) --push
5167DOCKER_BUILDX_PUSH_X_PLATFORM := $(DOCKER_BUILDX_PUSH) --platform ${DOCKER_BUILD_PLATFORM}
5268
53−DOCKER_BUILD_PLATFORM_ALPINE ?= linux/amd64,linux/arm64,linux/ppc64le,linux/arm/v6,linux/arm/v7
54−DOCKER_BUILD_RUNTIME_IMAGE_ALPINE ?= alpine:3.20.0
55−DOCKER_BUILDX_ARGS_ALPINE ?= --build-arg RUNTIME_IMAGE=${DOCKER_BUILD_RUNTIME_IMAGE_ALPINE} --build-arg VERSION=${VERSION}
69+DOCKER_BUILD_PLATFORM_ALPINE ?= linux/amd64,linux/arm64,linux/ppc64le,linux/arm/v6,linux/arm/v7,linux/s390x
70+DOCKER_BUILD_RUNTIME_IMAGE_ALPINE ?= alpine:3.24.1
71+DOCKER_BUILDX_ARGS_ALPINE ?= --build-arg RUNTIME_IMAGE=${DOCKER_BUILD_RUNTIME_IMAGE_ALPINE} ${DOCKER_BUILDX_COMMON_ARGS}
5672DOCKER_BUILDX_X_PLATFORM_ALPINE := docker buildx build ${DOCKER_BUILDX_ARGS_ALPINE} --platform ${DOCKER_BUILD_PLATFORM_ALPINE}
5773DOCKER_BUILDX_PUSH_X_PLATFORM_ALPINE := $(DOCKER_BUILDX_X_PLATFORM_ALPINE) --push
5874
59−.PHONY: docker
60−docker:
75+.PHONY: build-docker
76+build-docker: build-distroless build-alpine ## Build multi architecture docker images in both flavours (distroless / alpine)
77+
78+.PHONY: build-docker-local
79+build-docker-local: ## Build distroless docker image and locally load into docker images
80+ $(DOCKER_BUILDX) --load -t $(REGISTRY)/$(REPOSITORY):${VERSION}-local .
81+
82+.PHONY: build-distroless
83+build-distroless: ## Build multi architecture distroless based docker image
6184 $(DOCKER_BUILDX_X_PLATFORM) -t $(REGISTRY)/$(REPOSITORY):latest -t $(REGISTRY)/$(REPOSITORY):${VERSION} .
62− $(DOCKER_BUILDX_X_PLATFORM_ALPINE) -t $(REGISTRY)/$(REPOSITORY):latest-alpine -t $(REGISTRY)/$(REPOSITORY):${VERSION}-alpine .
6385
64−.PHONY: docker-push
65−docker-push:
66− $(DOCKER_BUILDX_PUSH_X_PLATFORM) -t $(REGISTRY)/$(REPOSITORY):latest -t $(REGISTRY)/$(REPOSITORY):${VERSION} .
67− $(DOCKER_BUILDX_PUSH_X_PLATFORM_ALPINE) -t $(REGISTRY)/$(REPOSITORY):latest-alpine -t $(REGISTRY)/$(REPOSITORY):${VERSION}-alpine .
86+.PHONY: build-alpine
87+build-alpine: ## Build multi architecture alpine based docker image
88+ $(DOCKER_BUILDX_X_PLATFORM_ALPINE) -t $(REGISTRY)/$(REPOSITORY):latest-alpine -t $(REGISTRY)/$(REPOSITORY):${VERSION}-alpine .
6889
69−.PHONY: docker-all
70−docker-all: docker
90+.PHONY: build-docker-all
91+build-docker-all: build-docker ## Build docker images for all supported architectures in both flavours (distroless / alpine)
7192 $(DOCKER_BUILDX) --platform linux/amd64 -t $(REGISTRY)/$(REPOSITORY):latest-amd64 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-amd64 .
7293 $(DOCKER_BUILDX) --platform linux/arm64 -t $(REGISTRY)/$(REPOSITORY):latest-arm64 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-arm64 .
7394 $(DOCKER_BUILDX) --platform linux/ppc64le -t $(REGISTRY)/$(REPOSITORY):latest-ppc64le -t $(REGISTRY)/$(REPOSITORY):${VERSION}-ppc64le .
74− $(DOCKER_BUILDX) --platform linux/arm/v6 -t $(REGISTRY)/$(REPOSITORY):latest-armv6 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-armv6 .
7595 $(DOCKER_BUILDX) --platform linux/arm/v7 -t $(REGISTRY)/$(REPOSITORY):latest-armv7 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-armv7 .
96+ $(DOCKER_BUILDX) --platform linux/s390x -t $(REGISTRY)/$(REPOSITORY):latest-s390x -t $(REGISTRY)/$(REPOSITORY):${VERSION}-s390x .
97+
98+
99+##@ Publish
100+
101+.PHONY: push-docker
102+push-docker: push-distroless push-alpine ## Push multi architecture docker images for both flavours (distroless / alpine)
103+
104+.PHONY: push-distroless
105+push-distroless: ## Push multi architecture distroless based docker image
106+ $(DOCKER_BUILDX_PUSH_X_PLATFORM) -t $(REGISTRY)/$(REPOSITORY):latest -t $(REGISTRY)/$(REPOSITORY):${VERSION} .
107+
108+.PHONY: push-alpine
109+push-alpine: ## Push multi architecture alpine based docker image
110+ $(DOCKER_BUILDX_PUSH_X_PLATFORM_ALPINE) -t $(REGISTRY)/$(REPOSITORY):latest-alpine -t $(REGISTRY)/$(REPOSITORY):${VERSION}-alpine .
76111
77−.PHONY: docker-push-all
78−docker-push-all: docker-push
112+.PHONY: push-docker-all
113+push-docker-all: push-docker ## Push docker images for all supported architectures for both flavours (distroless / alpine)
79114 $(DOCKER_BUILDX_PUSH) --platform linux/amd64 -t $(REGISTRY)/$(REPOSITORY):latest-amd64 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-amd64 .
80115 $(DOCKER_BUILDX_PUSH) --platform linux/arm64 -t $(REGISTRY)/$(REPOSITORY):latest-arm64 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-arm64 .
81116 $(DOCKER_BUILDX_PUSH) --platform linux/ppc64le -t $(REGISTRY)/$(REPOSITORY):latest-ppc64le -t $(REGISTRY)/$(REPOSITORY):${VERSION}-ppc64le .
82− $(DOCKER_BUILDX_PUSH) --platform linux/arm/v6 -t $(REGISTRY)/$(REPOSITORY):latest-armv6 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-armv6 .
83117 $(DOCKER_BUILDX_PUSH) --platform linux/arm/v7 -t $(REGISTRY)/$(REPOSITORY):latest-armv7 -t $(REGISTRY)/$(REPOSITORY):${VERSION}-armv7 .
118+ $(DOCKER_BUILDX_PUSH) --platform linux/s390x -t $(REGISTRY)/$(REPOSITORY):latest-s390x -t $(REGISTRY)/$(REPOSITORY):${VERSION}-s390x .
119+
120+
121+##@ Nightly scheduling
84122
85−.PHONY: docker-nightly-build
86−docker-nightly-build:
123+.PHONY: nightly-build
124+nightly-build: ## Nightly build command for docker images in both flavours (distroless / alpine)
87125 $(DOCKER_BUILDX_X_PLATFORM) -t $(REGISTRY)/$(REPOSITORY)-nightly:latest -t $(REGISTRY)/$(REPOSITORY)-nightly:${DATE} .
88126 $(DOCKER_BUILDX_X_PLATFORM_ALPINE) -t ${REGISTRY}/$(REPOSITORY)-nightly:latest-alpine -t $(REGISTRY)/$(REPOSITORY)-nightly:${DATE}-alpine .
89127
90−.PHONY: docker-nightly-push
91−docker-nightly-push:
128+.PHONY: nightly-push
129+nightly-push: ## Nightly push command for docker images in both flavours (distroless / alpine)
92130 $(DOCKER_BUILDX_PUSH_X_PLATFORM) -t $(REGISTRY)/$(REPOSITORY)-nightly:latest -t $(REGISTRY)/$(REPOSITORY)-nightly:${DATE} .
93131 $(DOCKER_BUILDX_PUSH_X_PLATFORM_ALPINE) -t ${REGISTRY}/$(REPOSITORY)-nightly:latest-alpine -t $(REGISTRY)/$(REPOSITORY)-nightly:${DATE}-alpine .
94132
133+
134+##@ Docs
135+
95136.PHONY: generate
96−generate:
137+generate: ## Generate alpha config docs from golang structs
97138 go generate ./pkg/...
98139
99140.PHONY: verify-generate
100−verify-generate: generate
141+verify-generate: generate ## Verify command to check if alpha config docs are in line with golang struct changes
101142 git diff --exit-code
102143
144+##@ Miscellaneous
145+
103146.PHONY: test
104−test: lint
147+test: ## Run all Go tests
105148 GO111MODULE=on $(GO) test $(TESTCOVER) -v -race ./...
106149
107150.PHONY: release
108−release: validate-go-version lint test
151+release: validate-go-version ## Create a full release for all architectures (binaries and checksums)
109152 BINARY=${BINARY} VERSION=${VERSION} ./dist.sh
110153
154+.PHONY: clean
155+clean: ## Cleanup release and build files
156+ -rm -rf release
157+ -rm -f $(BINARY)
158+
159+.PHONY: lint
160+lint: validate-go-version ## Lint all files using golangci-lint
161+ GO111MODULE=on $(GO) run github.com/golangci/golangci-lint/v2/cmd/golangci-lint@$(GOLANGCILINT_VERSION) run --timeout 10m
162+
163+.PHONY: lint-fix
164+lint-fix: validate-go-version ## Lint all files and apply fixes using golangci-lint
165+ GO111MODULE=on $(GO) run github.com/golangci/golangci-lint/v2/cmd/golangci-lint@$(GOLANGCILINT_VERSION) run --timeout 10m --fix
166+
111167.PHONY: validate-go-version
112−validate-go-version:
113− @if [ $(GO_MAJOR_VERSION) -gt $(MINIMUM_SUPPORTED_GO_MAJOR_VERSION) ]; then \
114− exit 0 ;\
115− elif [ $(GO_MAJOR_VERSION) -lt $(MINIMUM_SUPPORTED_GO_MAJOR_VERSION) ]; then \
116− echo '$(GO_VERSION_VALIDATION_ERR_MSG)';\
117− exit 1; \
118− elif [ $(GO_MINOR_VERSION) -lt $(MINIMUM_SUPPORTED_GO_MINOR_VERSION) ] ; then \
119− echo '$(GO_VERSION_VALIDATION_ERR_MSG)';\
120− exit 1; \
121− fi
168+validate-go-version: ## Validate Go environment requirements
169+ @$(GO) list . >/dev/null || { echo '$(GO_VERSION_VALIDATION_ERR_MSG)'; exit 1; }
122170
123171# local-env can be used to interact with the local development environment
124172# eg:
README.md+74−47
@@ -1,78 +1,105 @@
1+[![Continuous Integration](https://github.com/oauth2-proxy/oauth2-proxy/actions/workflows/ci.yml/badge.svg)](https://github.com/oauth2-proxy/oauth2-proxy/actions/workflows/ci.yml)
2+[![Go Report Card](https://goreportcard.com/badge/github.com/oauth2-proxy/oauth2-proxy)](https://goreportcard.com/report/github.com/oauth2-proxy/oauth2-proxy/v7)
3+[![GoDoc](https://godoc.org/github.com/oauth2-proxy/oauth2-proxy?status.svg)](https://godoc.org/github.com/oauth2-proxy/oauth2-proxy/v7)
4+[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
5+[![Maintainability](https://qlty.sh/gh/oauth2-proxy/projects/oauth2-proxy/maintainability.svg)](https://qlty.sh/gh/oauth2-proxy/projects/oauth2-proxy)
6+[![Code Coverage](https://qlty.sh/gh/oauth2-proxy/projects/oauth2-proxy/coverage.svg)](https://qlty.sh/gh/oauth2-proxy/projects/oauth2-proxy)
7+[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/oauth2-proxy/oauth2-proxy/badge)](https://scorecard.dev/viewer/?uri=github.com/oauth2-proxy/oauth2-proxy)
8+[![OpenSSF Best Practices](https://www.bestpractices.dev/projects/11223/badge)](https://www.bestpractices.dev/projects/11223)
9+[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Foauth2-proxy%2Foauth2-proxy.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Foauth2-proxy%2Foauth2-proxy?ref=badge_shield)
10+
111![OAuth2 Proxy](docs/static/img/logos/OAuth2_Proxy_horizontal.svg)
212
3−[![Continuous Integration](https://github.com/oauth2-proxy/oauth2-proxy/actions/workflows/ci.yaml/badge.svg)](https://github.com/oauth2-proxy/oauth2-proxy/actions/workflows/ci.yaml)
4−[![Go Report Card](https://goreportcard.com/badge/github.com/oauth2-proxy/oauth2-proxy)](https://goreportcard.com/report/github.com/oauth2-proxy/oauth2-proxy)
5−[![GoDoc](https://godoc.org/github.com/oauth2-proxy/oauth2-proxy?status.svg)](https://godoc.org/github.com/oauth2-proxy/oauth2-proxy)
6−[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
7−[![Maintainability](https://api.codeclimate.com/v1/badges/a58ff79407212e2beacb/maintainability)](https://codeclimate.com/github/oauth2-proxy/oauth2-proxy/maintainability)
8−[![Test Coverage](https://api.codeclimate.com/v1/badges/a58ff79407212e2beacb/test_coverage)](https://codeclimate.com/github/oauth2-proxy/oauth2-proxy/test_coverage)
13+OAuth2 Proxy is a flexible, open-source tool that can act as either a standalone reverse proxy or a middleware component integrated into existing reverse proxy or load balancer setups. It provides a simple and secure way to protect your web applications with OAuth2 / OIDC authentication. As a reverse proxy, it intercepts requests to your application and redirects users to an OAuth2 provider for authentication. As a middleware, it can be seamlessly integrated into your existing infrastructure to handle authentication for multiple applications.
14+
15+OAuth2 Proxy supports a lot of OAuth2 as well as OIDC providers. Either through a generic OIDC client or a specific implementation for Google, Microsoft Entra ID, GitHub, login.gov and others. Through specialised provider implementations OAuth2 Proxy can extract more details about the user like preferred usernames and groups. Those details can then be forwarded as HTTP headers to your upstream applications.
16+
17+![Simplified Architecture](docs/static/img/simplified-architecture.svg)
18+
19+## Get Started
920
10−A reverse proxy and static file server that provides authentication using Providers (Google, Keycloak, GitHub and others)
11−to validate accounts by email, domain or group.
21+OAuth2 Proxy's [Installation Docs](https://oauth2-proxy.github.io/oauth2-proxy/installation) cover how to install and configure your setup. Additionally you can take a further look at the [example setup files](https://github.com/oauth2-proxy/oauth2-proxy/tree/master/contrib/local-environment).
1222
13−**Note:** This repository was forked from [bitly/OAuth2_Proxy](https://github.com/bitly/oauth2_proxy) on 27/11/2018.
14−Versions v3.0.0 and up are from this fork and will have diverged from any changes in the original fork.
15−A list of changes can be seen in the [CHANGELOG](CHANGELOG.md).
23+## Releases
1624
17−**Note:** This project was formerly hosted as `pusher/oauth2_proxy` but has been renamed as of 29/03/2020 to `oauth2-proxy/oauth2-proxy`.
18−Going forward, all images shall be available at `quay.io/oauth2-proxy/oauth2-proxy` and binaries will be named `oauth2-proxy`.
25+### Binaries
26+We publish OAuth2 Proxy as compiled binaries on GitHub for all major architectures as well as more exotic ones like `ppc64le` as well as `s390x`.
1927
20−![Sign In Page](docs/static/img/sign-in-page.png)
28+Check out the [latest release](https://github.com/oauth2-proxy/oauth2-proxy/releases/latest).
2129
22−## Installation
30+### Images
2331
24−1. Choose how to deploy:
32+From `v7.6.0` and up the base image has been changed from Alpine to [GoogleContainerTools/distroless](https://github.com/GoogleContainerTools/distroless).
33+This image comes with even fewer installed dependencies and thus should improve security. The image therefore is also slightly smaller than Alpine.
34+For debugging purposes (and those who really need it. e.g. `armv6`) we still provide images based on Alpine. The tags of these images are suffixed with `-alpine`.
35+
36+Since 2023-11-18 we build nightly images directly from the `master` branch and provide them at `quay.io/oauth2-proxy/oauth2-proxy-nightly`.
37+These images are considered unstable and therefore should **NOT** be used for production purposes unless you know what you're doing.
2538
26− a. Using a [Prebuilt Binary](https://github.com/oauth2-proxy/oauth2-proxy/releases) (current release is `v7.6.0`)
39+## Sponsors
40+Would you like to sponsor the project then please contact us at [sponsors@oauth2-proxy.dev](mailto:sponsors@oauth2-proxy.dev)
2741
28− b. Using Go to install the latest release
29− ```bash
30− $ go install github.com/oauth2-proxy/oauth2-proxy/v7@latest
31− ```
32− This will install the binary into `$GOPATH/bin`. Make sure you include `$GOPATH` in your `$PATH`. Otherwise your system won't find binaries installed via `go install`
42+![SAP](https://avatars.githubusercontent.com/u/2531208?s=300&v=4)
3343
34− c. Using a [Prebuilt Docker Image](https://quay.io/oauth2-proxy/oauth2-proxy) (AMD64, PPC64LE, ARMv6, ARMv7, and ARM64 available)
44+SAP Open Source Program
3545
36− d. Using a [Pre-Release Nightly Docker Image](https://quay.io/oauth2-proxy/oauth2-proxy-nightly) (AMD64, PPC64LE, ARMv6, ARMv7, and ARM64 available)
46+## Former Sponsors
47+![Microsoft](https://avatars.githubusercontent.com/u/6154722?s=100&v=4)
48+
49+Microsoft Azure credits for open source projects
50+
51+## Getting Involved
52+[![Slack](https://img.shields.io/badge/slack-CNCF_%23oauth2--proxy-blue?logo=slack)](https://cloud-native.slack.com/archives/C098Y5URZ2N)
3753
38− e. Using the official [Kubernetes manifest](https://github.com/oauth2-proxy/manifests) (Helm)
54+Join the #oauth2-proxy [Slack channel](https://cloud-native.slack.com/archives/C098Y5URZ2N) to chat with other users of OAuth2 Proxy or reach out to the maintainers directly. Use the [public invite link](https://slack.cncf.io/) to get an invite for the CNCF space.
3955
40− Prebuilt binaries can be validated by extracting the file and verifying it against the `sha256sum.txt` checksum file provided for each release starting with version `v3.0.0`.
56+OAuth2 Proxy is a community-driven project. We rely on the contribut️ions of our users to continually improve it. While review times can vary, we appreciate your patience and understanding. As a volunteer-driven project, we strive to keep this project stable and might take longer to merge changes.
4157
42− ```
43− sha256sum -c sha256sum.txt 2>&1 | grep OK
44− oauth2-proxy-x.y.z.linux-amd64: OK
45− ```
58+If you want to contribute to the project. Please see our [Contributing](https://oauth2-proxy.github.io/oauth2-proxy/community/contribution) guide.
4659
47−2. [Select a Provider and Register an OAuth Application with a Provider](https://oauth2-proxy.github.io/oauth2-proxy/configuration/providers/)
48−3. [Configure OAuth2 Proxy using config file, command line options, or environment variables](https://oauth2-proxy.github.io/oauth2-proxy/configuration/overview)
49−4. [Configure SSL or Deploy behind a SSL endpoint](https://oauth2-proxy.github.io/oauth2-proxy/configuration/tls) (example provided for Nginx)
60+Thanks to all the people who already contributed ❤
5061
62+<a href="https://github.com/oauth2-proxy/oauth2-proxy/graphs/contributors">
63+ <img src="https://contrib.rocks/image?repo=oauth2-proxy/oauth2-proxy&columns=15&max=75" />
64+ <img src="https://img.shields.io/github/contributors/oauth2-proxy/oauth2-proxy" />
65+</a>
66+
67+Made with [contrib.rocks](https://contrib.rocks).
5168
5269## Security
5370
54−If you are running a version older than v6.0.0 we **strongly recommend you please update** to a current version.
71+If you believe you have found a vulnerability within OAuth2 Proxy or any of its dependencies, please do **NOT** open an issue or PR on GitHub, please do **NOT** post any details publicly.
72+
73+Security disclosures **MUST** be done in private. If you have found an issue that you would like to bring to the attention of the maintainers, please compose an email and send it to the list of people listed in our [MAINTAINERS.md](MAINTAINERS.md) file.
74+
75+For more details read our full [Security Docs](https://oauth2-proxy.github.io/oauth2-proxy/community/security#security-disclosures)
76+
77+### Security Notice for v6.0.0 and older
78+
79+If you are running a version older than v6.0.0 we **strongly recommend** to the current version.
80+
5581See [open redirect vulnerability](https://github.com/oauth2-proxy/oauth2-proxy/security/advisories/GHSA-5m6c-jp6f-2vcv) for details.
5682
57−## Docs
83+## Repository History
5884
59−Read the docs on our [Docs site](https://oauth2-proxy.github.io/oauth2-proxy/).
85+**2018-11-27:** This repository was forked from [bitly/OAuth2_Proxy](https://github.com/bitly/oauth2_proxy). Versions v3.0.0 and up are from this fork and will have diverged from any changes in the original fork. A list of changes can be seen in the [CHANGELOG](CHANGELOG.md).
6086
61−![OAuth2 Proxy Architecture](docs/static/img/architecture.svg)
87+**2020-03-29:** This project was formerly hosted as `pusher/oauth2_proxy` but has been renamed to `oauth2-proxy/oauth2-proxy`. Going forward, all images shall be available at `quay.io/oauth2-proxy/oauth2-proxy` and binaries will be named `oauth2-proxy`.
6288
63−## Images
89+## Code of Conduct
90+Participation in the OAuth2 Proxy project is governed by the [CNCF Code of Conduct](CODE_OF_CONDUCT.md).
6491
65−From `v7.6.0` and up the base image has been changed from Alpine to [GoogleContainerTools/distroless](https://github.com/GoogleContainerTools/distroless).
66−This image comes with even fewer installed dependencies and thus should improve security. The image therefore is also slightly smaller than Alpine.
67−For debugging purposes (and those who really need it (i.e. `armv6`)) we still provide images based on Alpine. The tags of these images are suffixed with `-alpine`.
92+## License
6893
69−Since 2023-11-18 we provide nightly images. These images are build and pushed nightly to `quay.io/oauth2-proxy/oauth2-proxy-nightly` from `master`.
70−These images should be considered alpha and therefore *should not* be used for production purposes unless you know what you're doing.
94+OAuth2 Proxy is distributed under [The MIT License](LICENSE).
7195
72−## Getting Involved
7396
74−If you would like to reach out to the maintainers, come talk to us in the `#oauth2-proxy` channel in the [Gophers slack](http://gophers.slack.com/).
97+[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Foauth2-proxy%2Foauth2-proxy.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Foauth2-proxy%2Foauth2-proxy?ref=badge_large)
98+
99+## Trademarks
100+
101+OAuth2 Proxy is a [Cloud Native Computing Foundation](https://cncf.io) Sandbox project.
75102
76−## Contributing
103+![CNCF](https://www.cncf.io/wp-content/uploads/2023/04/cncf-main-site-logo.svg)
77104
78−Please see our [Contributing](CONTRIBUTING.md) guidelines. For releasing see our [release creation guide](RELEASE.md).
105+The Linux Foundation® (TLF) has registered trademarks and uses trademarks. For a list of TLF trademarks, see [Trademark Usage](https://www.linuxfoundation.org/legal/trademark-usage).
RELEASE.md+2−2
@@ -41,8 +41,8 @@ Note this uses `v4.1.0` as an example release number.
414110. Publish release in Github
424211. Make and push docker images to Quay
4343 ```
44− make docker-all
45− make docker-push-all
44+ make build-docker-all
45+ make push-docker-all
4646 ```
4747 Note: Ensure the docker tags don't include `-dirty`. This means you have uncommitted changes.
4848
contrib/local-environment/Makefile+2−2
@@ -49,8 +49,8 @@ kubernetes-down:
4949
5050.PHONY: traefik-up
5151traefik-up:
52− docker compose -f docker-compose.yaml -f docker-compose-traefik.yaml up -d
52+ docker compose -f docker-compose-traefik.yaml up -d
5353
5454.PHONY: traefik-%
5555traefik-%:
56− docker compose -f docker-compose.yaml -f docker-compose-traefik.yaml $*
56+ docker compose -f docker-compose-traefik.yaml $*
contrib/local-environment/dex-traefik.yamlnew file+25
@@ -0,0 +1,25 @@
1+# This configuration is intended to be used with the Traefik local environment.
2+# Dex uses in-memory storage because this environment is disposable.
3+issuer: http://dex.localtest.me/dex
4+storage:
5+ type: memory
6+web:
7+ http: 0.0.0.0:5556
8+oauth2:
9+ skipApprovalScreen: true
10+expiry:
11+ signingKeys: "4h"
12+ idTokens: "1h"
13+staticClients:
14+ - id: oauth2-proxy
15+ redirectURIs:
16+ - "http://oauth2-proxy.localtest.me/oauth2/callback"
17+ name: "OAuth2 Proxy"
18+ secret: b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK
19+enablePasswordDB: true
20+staticPasswords:
21+ - email: "admin@example.com"
22+ # bcrypt hash of the string "password"
23+ hash: "$2a$10$2b2cU8CPhOTaGrs1HRQuAueS7JTT5ZHsHSzYiFPm1leZck7Mc8T4W"
24+ username: "admin"
25+ userID: "08a8684b-db88-4b73-90a9-3cd1661f5466"
contrib/local-environment/dex.yaml+16−20
@@ -1,32 +1,28 @@
11# This configuration is intended to be used with the docker-compose testing
22# environment.
3−# This should configure Dex to run on port 4190 and provides a static login
4−issuer: http://dex.localtest.me:4190/dex
3+# This should configure Dex to run on port 5556 and provides a static login
4+issuer: http://dex.localtest.me:5556/dex
55storage:
6− type: etcd
7− config:
8− endpoints:
9− - http://etcd:2379
10− namespace: dex/
6+ type: memory
117web:
12− http: 0.0.0.0:4190
8+ http: 0.0.0.0:5556
139oauth2:
1410 skipApprovalScreen: true
1511expiry:
1612 signingKeys: "4h"
1713 idTokens: "1h"
1814staticClients:
19−- id: oauth2-proxy
20− redirectURIs:
21− # These redirect URIs point to the `--redirect-url` for OAuth2 proxy.
22− - 'http://oauth2-proxy.localtest.me:4180/oauth2/callback' # For basic proxy example.
23− - 'http://oauth2-proxy.oauth2-proxy.localhost/oauth2/callback' # For nginx and traefik example.
24− name: 'OAuth2 Proxy'
25− secret: b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK
15+ - id: oauth2-proxy
16+ redirectURIs:
17+ # These redirect URIs point to the `--redirect-url` for OAuth2 proxy.
18+ - "http://oauth2-proxy.localtest.me:4180/oauth2/callback" # For basic proxy example.
19+ - "http://oauth2-proxy.localtest.me:8080/oauth2/callback" # For nginx example.
20+ name: "OAuth2 Proxy"
21+ secret: b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK
2622enablePasswordDB: true
2723staticPasswords:
28−- email: "admin@example.com"
29− # bcrypt hash of the string "password"
30− hash: "$2a$10$2b2cU8CPhOTaGrs1HRQuAueS7JTT5ZHsHSzYiFPm1leZck7Mc8T4W"
31− username: "admin"
32− userID: "08a8684b-db88-4b73-90a9-3cd1661f5466"
24+ - email: "admin@example.com"
25+ # bcrypt hash of the string "password"
26+ hash: "$2a$10$2b2cU8CPhOTaGrs1HRQuAueS7JTT5ZHsHSzYiFPm1leZck7Mc8T4W"
27+ username: "admin"
28+ userID: "08a8684b-db88-4b73-90a9-3cd1661f5466"
contrib/local-environment/docker-compose-alpha-config.yaml+37−2
@@ -1,7 +1,7 @@
11# This docker-compose file can be used to bring up an example instance of oauth2-proxy
22# for manual testing and exploration of features.
33# Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider,
4−# etcd for storage for Dex and HTTPBin as an example upstream.
4+# HTTPBin as an example upstream.
55# This file also uses alpha configuration when configuring OAuth2 Proxy.
66#
77# This file is an extension of the main compose file and must be used with it
@@ -10,10 +10,45 @@
1010# make alpha-config-<command> (eg make nginx-up, make nginx-down)
1111#
1212# Access http://localhost:4180 to initiate a login cycle
13−version: '3.0'
13+version: "3.0"
1414services:
1515 oauth2-proxy:
16+ container_name: oauth2-proxy
17+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
1618 command: --config /oauth2-proxy.cfg --alpha-config /oauth2-proxy-alpha-config.yaml
19+ hostname: oauth2-proxy
1720 volumes:
1821 - "./oauth2-proxy-alpha-config.cfg:/oauth2-proxy.cfg"
1922 - "./oauth2-proxy-alpha-config.yaml:/oauth2-proxy-alpha-config.yaml"
23+ restart: unless-stopped
24+ ports:
25+ - 4180:4180/tcp
26+ networks:
27+ dex: {}
28+ httpbin: {}
29+ depends_on:
30+ - dex
31+ - httpbin
32+ dex:
33+ container_name: dex
34+ image: ghcr.io/dexidp/dex:v2.45.1
35+ command: dex serve /dex.yaml
36+ hostname: dex
37+ volumes:
38+ - "./dex.yaml:/dex.yaml"
39+ restart: unless-stopped
40+ ports:
41+ - 5556:5556/tcp
42+ networks:
43+ dex:
44+ aliases:
45+ - dex.localtest.me
46+ httpbin:
47+ container_name: httpbin
48+ image: kennethreitz/httpbin
49+ ports: []
50+ networks:
51+ httpbin: {}
52+networks:
53+ dex: {}
54+ httpbin: {}
contrib/local-environment/docker-compose-gitea.yaml+4−7
@@ -14,7 +14,7 @@ version: '3.0'
1414services:
1515 oauth2-proxy:
1616 container_name: oauth2-proxy
17− image: quay.io/oauth2-proxy/oauth2-proxy:v7.6.0
17+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
1818 command: --config /oauth2-proxy.cfg
1919 hostname: oauth2-proxy
2020 volumes:
@@ -34,15 +34,12 @@ services:
3434 container_name: httpbin
3535 image: kennethreitz/httpbin:latest
3636 hostname: httpbin
37− ports:
38− - 8080:80
37+ ports: []
3938 networks:
40− httpbin:
41− aliases:
42− - httpbin.localtest.me
39+ httpbin: {}
4340
4441 gitea:
45− image: gitea/gitea:1.22.1
42+ image: gitea/gitea:1.27.2
4643 container_name: gitea
4744 environment:
4845 - USER_UID=1000
contrib/local-environment/docker-compose-keycloak.yaml+12−20
@@ -10,11 +10,11 @@
1010#
1111# Access http://oauth2-proxy.localtest.me:4180 to initiate a login cycle using user=admin@example.com, password=password
1212# Access http://keycloak.localtest.me:9080 with the same credentials to check out the settings
13−version: '3.0'
13+version: "3.0"
1414services:
1515 oauth2-proxy:
1616 container_name: oauth2-proxy
17− image: quay.io/oauth2-proxy/oauth2-proxy:v7.6.0
17+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
1818 command: --config /oauth2-proxy.cfg
1919 hostname: oauth2-proxy
2020 volumes:
@@ -34,32 +34,24 @@ services:
3434 container_name: httpbin
3535 image: kennethreitz/httpbin:latest
3636 hostname: httpbin
37− ports:
38− - 8080:80/tcp
37+ ports: []
3938 networks:
40− httpbin:
41− aliases:
42− - httpbin.localtest.me
39+ httpbin: {}
4340
4441 keycloak:
4542 container_name: keycloak
46− image: jboss/keycloak:10.0.2
43+ image: keycloak/keycloak:26.7
4744 hostname: keycloak
4845 command:
49− [
50− '-b',
51− '0.0.0.0',
52− '-Djboss.socket.binding.port-offset=1000',
53− '-Dkeycloak.migration.action=import',
54− '-Dkeycloak.migration.provider=dir',
55− '-Dkeycloak.migration.dir=/realm-config',
56− '-Dkeycloak.migration.strategy=IGNORE_EXISTING'
57− ]
46+ - "start-dev"
47+ - "--http-port=9080"
48+ - "--import-realm"
5849 volumes:
59− - ./keycloak:/realm-config
50+ - ./keycloak:/opt/keycloak/data/import
6051 environment:
61− KEYCLOAK_USER: admin@example.com
62− KEYCLOAK_PASSWORD: password
52+ KC_HTTP_PORT: 9080
53+ KEYCLOAK_ADMIN: admin@example.com
54+ KEYCLOAK_ADMIN_PASSWORD: password
6355 ports:
6456 - 9080:9080/tcp
6557 networks:
contrib/local-environment/docker-compose-nginx.yaml+39−15
@@ -1,44 +1,68 @@
11# This docker-compose file can be used to bring up an example instance of oauth2-proxy
22# for manual testing and exploration of features.
33# Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider,
4−# etcd for storage for Dex, nginx as a reverse proxy and other http services for upstreams
4+# nginx as a reverse proxy and other HTTP services for upstreams.
55#
66# This file is an extension of the main compose file and must be used with it
77# docker-compose -f docker-compose.yaml -f docker-compose-nginx.yaml <command>
88# Alternatively:
99# make nginx-<command> (eg make nginx-up, make nginx-down)
1010#
11−# Access one of the following URLs to initiate a login flow:
12−# - http://oauth2-proxy.localhost
13−# - http://httpbin.oauth2-proxy.localhost
14−#
15−# The OAuth2 Proxy itself is hosted at http://oauth2-proxy.oauth2-proxy.localhost
16−#
17−# Note, the above URLs should work with Chrome, but you may need to add hosts
18−# entries for other browsers
19−# 127.0.0.1 oauth2-proxy.localhost
20−# 127.0.0.1 httpbin.oauth2-proxy.localhost
21−# 127.0.0.1 oauth2-proxy.oauth2-proxy.localhost
22−version: '3.0'
11+# Access http://oauth2-proxy.localtest.me:8080 to initiate a login flow.
12+version: "3.0"
2313services:
2414 oauth2-proxy:
15+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
2516 ports: []
2617 hostname: oauth2-proxy
18+ container_name: oauth2-proxy
19+ command: --config /oauth2-proxy.cfg
20+ restart: unless-stopped
2721 volumes:
2822 - "./oauth2-proxy-nginx.cfg:/oauth2-proxy.cfg"
2923 networks:
3024 oauth2-proxy: {}
25+ dex: {}
26+ httpbin: {}
27+ depends_on:
28+ - dex
29+ - httpbin
3130 nginx:
31+ depends_on:
32+ - oauth2-proxy
3233 container_name: nginx
33− image: nginx:1.27
34+ image: nginx:1.31
3435 restart: unless-stopped
3536 ports:
36− - 80:80/tcp
37+ - 8080:8080/tcp
3738 hostname: nginx
3839 volumes:
3940 - "./nginx.conf:/etc/nginx/conf.d/default.conf"
4041 networks:
4142 oauth2-proxy: {}
43+ dex: {}
44+ httpbin: {}
45+ dex:
46+ container_name: dex
47+ image: ghcr.io/dexidp/dex:v2.45.1
48+ command: dex serve /dex.yaml
49+ hostname: dex
50+ volumes:
51+ - "./dex.yaml:/dex.yaml"
52+ restart: unless-stopped
53+ ports:
54+ - 5556:5556/tcp
55+ networks:
56+ dex:
57+ aliases:
58+ - dex.localtest.me
59+ httpbin:
60+ container_name: httpbin
61+ image: kennethreitz/httpbin
62+ ports: []
63+ networks:
4264 httpbin: {}
4365networks:
66+ dex: {}
67+ httpbin: {}
4468 oauth2-proxy: {}
contrib/local-environment/docker-compose-traefik.yaml+42−17
@@ -1,7 +1,7 @@
11# This docker-compose file can be used to bring up an example instance of oauth2-proxy
22# for manual testing and exploration of features.
3−# Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider,
4−# HTTPBin as an example upstream.
3+# Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider
4+# and HTTPBin as an example upstream.
55#
66# This can either be created using docker-compose
77# docker-compose -f docker-compose-traefik.yaml <command>
@@ -9,31 +9,51 @@
99# make traefik-<command> (eg. make traefik-up, make traefik-down)
1010#
1111# Access one of the following URLs to initiate a login flow:
12−# - http://oauth2-proxy.localhost
13−# - http://httpbin.oauth2-proxy.localhost
12+# - http://oauth2-proxy.localtest.me
13+# - http://httpbin.localtest.me
14+# - http://dex.localtest.me/dex
1415#
15−# The OAuth2 Proxy itself is hosted at http://oauth2-proxy.oauth2-proxy.localhost
16−#
17−# Note, the above URLs should work with Chrome, but you may need to add hosts
18−# entries for other browsers
19−# 127.0.0.1 oauth2-proxy.localhost
20−# 127.0.0.1 httpbin.oauth2-proxy.localhost
21−# 127.0.0.1 oauth2-proxy.oauth2-proxy.localhost
22−version: '3.0'
16+# The OAuth2 Proxy itself is hosted at http://oauth2-proxy.localtest.me
2317services:
2418
2519 oauth2-proxy:
20+ container_name: oauth2-proxy
21+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
22+ command: --config /oauth2-proxy.cfg
2623 ports: []
2724 hostname: oauth2-proxy
2825 volumes:
2926 - "./oauth2-proxy-traefik.cfg:/oauth2-proxy.cfg"
27+ restart: unless-stopped
28+ networks:
29+ oauth2-proxy: {}
30+ dex: {}
31+ depends_on:
32+ - dex
33+ - httpbin
34+
35+ dex:
36+ container_name: dex
37+ image: ghcr.io/dexidp/dex:v2.45.1
38+ command: dex serve /dex.yaml
39+ hostname: dex
40+ volumes:
41+ - "./dex-traefik.yaml:/dex.yaml"
42+ restart: unless-stopped
3043 networks:
31− oauth2-proxy:
44+ dex: {}
45+
46+ httpbin:
47+ container_name: httpbin
48+ image: kennethreitz/httpbin
49+ ports: []
50+ networks:
51+ httpbin: {}
3252
3353 # Reverse proxy
3454 gateway:
3555 container_name: traefik
36− image: traefik:v2.11.6
56+ image: traefik:v3.7.10
3757 volumes:
3858 - "./traefik:/etc/traefik"
3959 ports:
@@ -42,8 +62,13 @@ services:
4262 depends_on:
4363 - oauth2-proxy
4464 networks:
45− oauth2-proxy:
46− httpbin:
65+ oauth2-proxy: {}
66+ httpbin: {}
67+ dex:
68+ aliases:
69+ - dex.localtest.me
4770
4871networks:
49− oauth2-proxy:
72+ dex: {}
73+ httpbin: {}
74+ oauth2-proxy: {}
contrib/local-environment/docker-compose.yaml+7−23
@@ -1,7 +1,7 @@
11# This docker-compose file can be used to bring up an example instance of oauth2-proxy
22# for manual testing and exploration of features.
33# Alongside OAuth2-Proxy, this file also starts Dex to act as the identity provider,
4−# etcd for storage for Dex and HTTPBin as an example upstream.
4+# HTTPBin as an example upstream.
55#
66# This can either be created using docker-compose
77# docker-compose -f docker-compose.yaml <command>
@@ -9,11 +9,11 @@
99# make <command> (eg. make up, make down)
1010#
1111# Access http://oauth2-proxy.localtest.me:4180 to initiate a login cycle
12−version: '3.0'
12+version: "3.0"
1313services:
1414 oauth2-proxy:
1515 container_name: oauth2-proxy
16− image: quay.io/oauth2-proxy/oauth2-proxy:v7.6.0
16+ image: quay.io/oauth2-proxy/oauth2-proxy:v7.15.4
1717 command: --config /oauth2-proxy.cfg
1818 hostname: oauth2-proxy
1919 volumes:
@@ -29,40 +29,24 @@ services:
2929 - httpbin
3030 dex:
3131 container_name: dex
32− image: ghcr.io/dexidp/dex:v2.40.0
32+ image: ghcr.io/dexidp/dex:v2.45.1
3333 command: dex serve /dex.yaml
3434 hostname: dex
3535 volumes:
3636 - "./dex.yaml:/dex.yaml"
3737 restart: unless-stopped
3838 ports:
39− - 4190:4190/tcp
39+ - 5556:5556/tcp
4040 networks:
4141 dex:
4242 aliases:
4343 - dex.localtest.me
44− etcd: {}
45− depends_on:
46− - etcd
4744 httpbin:
4845 container_name: httpbin
4946 image: kennethreitz/httpbin
50− ports:
51− - 8080:80/tcp
47+ ports: []
5248 networks:
53− httpbin:
54− aliases:
55− - httpbin.localtest.me
56− etcd:
57− container_name: etcd
58− image: gcr.io/etcd-development/etcd:v3.5.14
59− entrypoint: /usr/local/bin/etcd
60− command:
61− - --listen-client-urls=http://0.0.0.0:2379
62− - --advertise-client-urls=http://etcd:2379
63− networks:
64− etcd: {}
49+ httpbin: {}
6550networks:
6651 dex: {}
67− etcd: {}
6852 httpbin: {}
contrib/local-environment/keycloak/master-realm.json → contrib/local-environment/keycloak/oauth2-proxy-realm.jsonrenamed+18−18
@@ -1,6 +1,6 @@
11{
2− "id": "master",
3− "realm": "master",
2+ "id": "oauth2-proxy",
3+ "realm": "oauth2-proxy",
44 "displayName": "Keycloak",
55 "displayNameHtml": "<div class=\"kc-logo-text\"><span>Keycloak</span></div>",
66 "notBefore": 0,
@@ -48,7 +48,7 @@
4848 "description": "${role_offline-access}",
4949 "composite": false,
5050 "clientRole": false,
51− "containerId": "master",
51+ "containerId": "oauth2-proxy",
5252 "attributes": {}
5353 },
5454 {
@@ -61,7 +61,7 @@
6161 "create-realm"
6262 ],
6363 "client": {
64− "master-realm": [
64+ "oauth2-proxy-realm": [
6565 "query-groups",
6666 "create-client",
6767 "query-realms",
@@ -84,7 +84,7 @@
8484 }
8585 },
8686 "clientRole": false,
87− "containerId": "master",
87+ "containerId": "oauth2-proxy",
8888 "attributes": {}
8989 },
9090 {
@@ -93,7 +93,7 @@
9393 "description": "${role_uma_authorization}",
9494 "composite": false,
9595 "clientRole": false,
96− "containerId": "master",
96+ "containerId": "oauth2-proxy",
9797 "attributes": {}
9898 },
9999 {
@@ -102,7 +102,7 @@
102102 "description": "${role_create-realm}",
103103 "composite": false,
104104 "clientRole": false,
105− "containerId": "master",
105+ "containerId": "oauth2-proxy",
106106 "attributes": {}
107107 }
108108 ],
@@ -122,7 +122,7 @@
122122 "attributes": {}
123123 }
124124 ],
125− "master-realm": [
125+ "oauth2-proxy-realm": [
126126 {
127127 "id": "a8271c2c-6437-4ca5-ae83-49ea5fe1318d",
128128 "name": "query-groups",
@@ -229,7 +229,7 @@
229229 "composite": true,
230230 "composites": {
231231 "client": {
232− "master-realm": [
232+ "oauth2-proxy-realm": [
233233 "query-groups",
234234 "query-users"
235235 ]
@@ -273,7 +273,7 @@
273273 "composite": true,
274274 "composites": {
275275 "client": {
276− "master-realm": [
276+ "oauth2-proxy-realm": [
277277 "query-clients"
278278 ]
279279 }
@@ -439,7 +439,7 @@
439439 "clientId": "account",
440440 "name": "${client_account}",
441441 "rootUrl": "${authBaseUrl}",
442− "baseUrl": "/realms/master/account/",
442+ "baseUrl": "/realms/oauth2-proxy/account/",
443443 "surrogateAuthRequired": false,
444444 "enabled": true,
445445 "alwaysDisplayInConsole": false,
@@ -450,7 +450,7 @@
450450 "manage-account"
451451 ],
452452 "redirectUris": [
453− "/realms/master/account/*"
453+ "/realms/oauth2-proxy/account/*"
454454 ],
455455 "webOrigins": [],
456456 "notBefore": 0,
@@ -486,14 +486,14 @@
486486 "clientId": "account-console",
487487 "name": "${client_account-console}",
488488 "rootUrl": "${authBaseUrl}",
489− "baseUrl": "/realms/master/account/",
489+ "baseUrl": "/realms/oauth2-proxy/account/",
490490 "surrogateAuthRequired": false,
491491 "enabled": true,
492492 "alwaysDisplayInConsole": false,
493493 "clientAuthenticatorType": "client-secret",
494494 "secret": "91f85142-ee18-4e30-9949-e5acb701bdee",
495495 "redirectUris": [
496− "/realms/master/account/*"
496+ "/realms/oauth2-proxy/account/*"
497497 ],
498498 "webOrigins": [],
499499 "notBefore": 0,
@@ -616,8 +616,8 @@
616616 },
617617 {
618618 "id": "7174c175-1887-4e57-b95b-969fe040deff",
619− "clientId": "master-realm",
620− "name": "master Realm",
619+ "clientId": "oauth2-proxy-realm",
620+ "name": "oauth2-proxy Realm",
621621 "surrogateAuthRequired": false,
622622 "enabled": true,
623623 "alwaysDisplayInConsole": false,
@@ -711,14 +711,14 @@
711711 "clientId": "security-admin-console",
712712 "name": "${client_security-admin-console}",
713713 "rootUrl": "${authAdminUrl}",
714− "baseUrl": "/admin/master/console/",
714+ "baseUrl": "/admin/oauth2-proxy/console/",
715715 "surrogateAuthRequired": false,
716716 "enabled": true,
717717 "alwaysDisplayInConsole": false,
718718 "clientAuthenticatorType": "client-secret",
719719 "secret": "b234b7aa-8417-410f-b3fd-c57434d3aa4a",
720720 "redirectUris": [
721− "/admin/master/console/*"
721+ "/admin/oauth2-proxy/console/*"
722722 ],
723723 "webOrigins": [
724724 "+"
contrib/local-environment/keycloak/master-users-0.json → contrib/local-environment/keycloak/oauth2-proxy-users-0.jsonrenamed+1−1
@@ -1,5 +1,5 @@
11{
2− "realm": "master",
2+ "realm": "oauth2-proxy",
33 "users": [
44 {
55 "id": "3356c0a0-d4d5-4436-9c5a-2299c71c08ec",
contrib/local-environment/kubernetes/Chart.lock+4−4
@@ -1,15 +1,15 @@
11dependencies:
22- name: dex
33 repository: https://charts.dexidp.io
4− version: 0.18.0
4+ version: 0.24.1
55- name: oauth2-proxy
66 repository: https://oauth2-proxy.github.io/manifests
7− version: 7.7.8
7+ version: 7.18.0
88- name: httpbin
99 repository: https://conservis.github.io/helm-charts
1010 version: 1.1.0
1111- name: hello-world
1212 repository: https://conservis.github.io/helm-charts
1313 version: 1.1.0
14−digest: sha256:c26e53581a09b08b446041f848196bb99111f9926327e2ba32bb426732eb91cb
15−generated: "2024-06-30T08:10:35.814725005Z"
14+digest: sha256:3fff8bf99cebcd20a73c984423d5f1c2dfa1e5a394f82a5dc60d9aaffe5361b7
15+generated: "2026-08-18T07:33:03.791274914Z"
contrib/local-environment/kubernetes/Chart.yaml+2−2
@@ -3,10 +3,10 @@ description: K8S example based on https://kind.sigs.k8s.io
33name: kubernetes
44dependencies:
55 - name: dex
6− version: 0.18.0
6+ version: 0.24.1
77 repository: https://charts.dexidp.io
88 - name: oauth2-proxy
9− version: &chartVersion 7.7.8
9+ version: &chartVersion 7.18.0
1010 repository: https://oauth2-proxy.github.io/manifests
1111 # https://github.com/postmanlabs/httpbin/issues/549 is still in progress, for now using a non-official chart
1212 - name: httpbin
contrib/local-environment/kubernetes/README.md+1
@@ -16,6 +16,7 @@ Then:
1616* `make deploy`
1717
1818Visit http://httpbin.localtest.me or http://hello-world.localtest.me/
19+Note: When accessing the service for the first time you will need to authenticate with Dex. It is configured using static credentials for testing. With username `admin@example.com` and password set to `password`.
1920
2021## Uninstall
2122
contrib/local-environment/kubernetes/values.yaml+11−5
@@ -2,8 +2,12 @@ dex:
22 ingress:
33 enabled: true
44 hosts:
5− - dex.localtest.me
6− grpc: false
5+ - host: dex.localtest.me
6+ paths:
7+ - path: /
8+ pathType: ImplementationSpecific
9+ grpc:
10+ enabled: false
711 certs:
812 grpc:
913 create: false
@@ -12,6 +16,11 @@ dex:
1216
1317 config:
1418 issuer: http://dex.localtest.me
19+ storage:
20+ type: kubernetes
21+ config:
22+ inCluster: true
23+ enablePasswordDB: true
1524 expiry:
1625 signingKeys: "4h"
1726 idTokens: "1h"
@@ -35,9 +44,6 @@ oauth2-proxy:
3544 enabled: true
3645 hosts:
3746 - oauth2-proxy.localtest.me
38− annotations:
39− nginx.ingress.kubernetes.io/server-snippet: |
40− large_client_header_buffers 4 32k;
4147 # pick up client_id and client_secret from configFile as opposed to helm .Values.config.clientID and .Values.config.clientSecret
4248 proxyVarsAsSecrets: false
4349 config:
contrib/local-environment/nginx.conf+31−73
@@ -1,86 +1,44 @@
1−# Reverse proxy to oauth2-proxy
2−server {
3− listen 80;
4− server_name oauth2-proxy.oauth2-proxy.localhost;
5−
6− location / {
7− proxy_set_header Host $host;
8− proxy_set_header X-Real-IP $remote_addr;
9−
10− proxy_pass http://oauth2-proxy:4180/;
11− }
12−}
13−
141# Reverse proxy to httpbin
152server {
16− listen 80;
17− server_name httpbin.oauth2-proxy.localhost;
18−
19− auth_request /internal-auth/oauth2/auth;
20−
21− # If the auth_request denies the request (401), redirect to the sign_in page
22− # and include the final rd URL back to the user's original request.
23− error_page 401 =403 http://oauth2-proxy.oauth2-proxy.localhost/oauth2/sign_in?rd=$scheme://$host$request_uri;
24−
25− # Alternatively send the request to `start` to skip the provider button
26− # error_page 401 = http://oauth2-proxy.oauth2-proxy.localhost/oauth2/start?rd=$scheme://$host$request_uri;
27−
28− location / {
29− proxy_pass http://httpbin/;
3+ listen 8080;
4+ server_name oauth2-proxy.localtest.me;
5+
6+ location /oauth2/ {
7+ proxy_pass http://oauth2-proxy:4180;
8+ proxy_set_header Host $host;
9+ proxy_set_header X-Real-IP $remote_addr;
10+ proxy_set_header X-Forwarded-Uri $request_uri;
11+ proxy_set_header X-Auth-Request-Redirect $request_uri;
3012 }
3113
32− # auth_request must be a URI so this allows an internal path to then proxy to
33− # the real auth_request path.
34− # The trailing /'s are required so that nginx strips the prefix before proxying.
35− location /internal-auth/ {
36− internal; # Ensure external users can't access this path
37−
38− # Make sure the OAuth2 Proxy knows where the original request came from.
39− proxy_set_header Host $host;
40− proxy_set_header X-Real-IP $remote_addr;
41− proxy_set_header X-Forwarded-Uri $request_uri;
42−
43− proxy_pass http://oauth2-proxy:4180/;
14+ location = /oauth2/auth {
15+ proxy_pass http://oauth2-proxy:4180;
16+ proxy_set_header Host $host;
17+ proxy_set_header X-Real-IP $remote_addr;
18+ proxy_set_header X-Forwarded-Uri $request_uri;
19+ # nginx auth_request includes headers but not body
20+ proxy_set_header Content-Length "";
21+ proxy_pass_request_body off;
4422 }
45−}
46−
47−# Statically serve the nginx welcome
48−server {
49− listen 80;
50− server_name oauth2-proxy.localhost;
5123
5224 location / {
53− auth_request /internal-auth/oauth2/auth;
54−
55− # If the auth_request denies the request (401), redirect to the sign_in page
56− # and include the final rd URL back to the user's original request.
57− error_page 401 =403 http://oauth2-proxy.oauth2-proxy.localhost/oauth2/sign_in?rd=$scheme://$host$request_uri;
25+ auth_request /oauth2/auth;
26+ error_page 401 = @oauth2_signin;
5827
59− # Alternatively send the request to `start` to skip the provider button
60− # error_page 401 = http://oauth2-proxy.oauth2-proxy.localhost/oauth2/start?rd=$scheme://$host$request_uri;
28+ # pass information via X-User and X-Email headers to backend,
29+ # requires running with --set-xauthrequest flag
30+ auth_request_set $user $upstream_http_x_auth_request_user;
31+ auth_request_set $email $upstream_http_x_auth_request_email;
32+ proxy_set_header X-User $user;
33+ proxy_set_header X-Email $email;
6134
62−
63− root /usr/share/nginx/html;
64− index index.html index.htm;
65− }
66−
67− # redirect server error pages to the static page /50x.html
68− error_page 500 502 503 504 /50x.html;
69− location = /50x.html {
70− root /usr/share/nginx/html;
35+ proxy_pass http://httpbin/;
36+ # or "root /path/to/site;" or "fastcgi_pass ..." etc
7137 }
7238
73− # auth_request must be a URI so this allows an internal path to then proxy to
74− # the real auth_request path.
75− # The trailing /'s are required so that nginx strips the prefix before proxying.
76− location /internal-auth/ {
77− internal; # Ensure external users can't access this path
78−
79− # Make sure the OAuth2 Proxy knows where the original request came from.
80− proxy_set_header Host $host;
81− proxy_set_header X-Real-IP $remote_addr;
82− proxy_set_header X-Forwarded-Uri $request_uri;
83−
84− proxy_pass http://oauth2-proxy:4180/;
39+ # Named location for handling OAuth2 sign-in redirects
40+ # This ensures the browser receives a proper 302 redirect that it will follow
41+ location @oauth2_signin {
42+ return 302 /oauth2/sign_in?rd=$scheme://$http_host$request_uri;
8543 }
8644}
contrib/local-environment/oauth2-proxy-alpha-config.cfg+1−2
@@ -1,5 +1,4 @@
1−http_address="0.0.0.0:4180"
21cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w="
32email_domains="example.com"
43cookie_secure="false"
5−redirect_url="http://localhost:4180/oauth2/callback"
4+redirect_url="http://oauth2-proxy.localtest.me:4180/oauth2/callback"
contrib/local-environment/oauth2-proxy-alpha-config.yaml+21−21
@@ -1,23 +1,23 @@
1−upstreams:
2− - id: httpbin
3− path: /
4− uri: http://httpbin
1+server:
2+ bindAddress: "0.0.0.0:4180"
3+upstreamConfig:
4+ upstreams:
5+ - id: httpbin
6+ path: /
7+ uri: http://httpbin
58injectRequestHeaders:
6−- name: X-Forwarded-Groups
7− values:
8− - claim: groups
9−- name: X-Forwarded-User
10− values:
11− - claim: user
12−- name: X-Forwarded-Email
13− values:
14− - claim: email
15−- name: X-Forwarded-Preferred-Username
16− values:
17− - claim: preferred_username
9+ - name: X-Forwarded-User
10+ values:
11+ - claimSource:
12+ claim: user
13+ - name: X-Forwarded-Email
14+ values:
15+ - claimSource:
16+ claim: email
1817providers:
19−- provider: oidc
20− clientSecret: b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK
21− clientID: oauth2-proxy
22− oidcConfig:
23− issuerURL: http://dex.localhost:4190/dex
18+ - id: oidc
19+ provider: oidc
20+ clientSecret: b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK
21+ clientID: oauth2-proxy
22+ oidcConfig:
23+ issuerURL: http://dex.localtest.me:5556/dex
contrib/local-environment/oauth2-proxy-keycloak.cfg+4−4
@@ -2,8 +2,8 @@ http_address="0.0.0.0:4180"
22cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w="
33email_domains="example.com"
44cookie_secure="false"
5−upstreams="http://httpbin.localtest.me:8080"
6−cookie_domains=[".localtest.me"] # Required so cookie can be read on all subdomains.
5+upstreams="http://httpbin"
6+cookie_domains=["oauth2-proxy.localtest.me:4080", "keycloak.localtest.me:9080"] # Required so cookie can be read on all subdomains.
77whitelist_domains=[".localtest.me"] # Required to allow redirection back to original requested target.
88
99# keycloak provider
@@ -12,7 +12,7 @@ client_id="oauth2-proxy"
1212redirect_url="http://oauth2-proxy.localtest.me:4180/oauth2/callback"
1313
1414# in this case oauth2-proxy is going to visit
15−# http://keycloak.localtest.me:9080/auth/realms/master/.well-known/openid-configuration for configuration
16−oidc_issuer_url="http://keycloak.localtest.me:9080/auth/realms/master"
15+# http://keycloak.localtest.me:9080/realms/oauth2-proxy/.well-known/openid-configuration for configuration
16+oidc_issuer_url="http://keycloak.localtest.me:9080/realms/oauth2-proxy"
1717provider="oidc"
1818provider_display_name="Keycloak"
contrib/local-environment/oauth2-proxy-nginx.cfg+11−6
@@ -1,14 +1,19 @@
11http_address="0.0.0.0:4180"
22cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w="
3−provider="oidc"
43email_domains="example.com"
5−oidc_issuer_url="http://dex.localtest.me:4190/dex"
4+cookie_secure="false"
5+upstreams="static://200"
6+cookie_domains=[".localtest.me"] # Required so cookie can be read on all subdomains.
7+whitelist_domains=[".localtest.me"] # Required to allow redirection back to original requested target.
8+
9+# dex provider
610client_secret="b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK"
711client_id="oauth2-proxy"
8−cookie_secure="false"
12+redirect_url="http://oauth2-proxy.localtest.me:8080/oauth2/callback"
13+
14+oidc_issuer_url="http://dex.localtest.me:5556/dex"
15+provider="oidc"
16+provider_display_name="Dex"
917
10−redirect_url="http://oauth2-proxy.oauth2-proxy.localhost/oauth2/callback"
11−cookie_domains=".oauth2-proxy.localhost" # Required so cookie can be read on all subdomains.
12−whitelist_domains=".oauth2-proxy.localhost" # Required to allow redirection back to original requested target.
1318# Enables the use of `X-Forwarded-*` headers to determine request correctly
1419reverse_proxy="true"
contrib/local-environment/oauth2-proxy-traefik.cfg+5−5
@@ -2,18 +2,18 @@ http_address="0.0.0.0:4180"
22cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w="
33provider="oidc"
44email_domains=["example.com"]
5−oidc_issuer_url="http://dex.localhost:4190/dex"
5+oidc_issuer_url="http://dex.localtest.me/dex"
66client_secret="b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK"
77client_id="oauth2-proxy"
88cookie_secure="false"
99
10−redirect_url="http://oauth2-proxy.oauth2-proxy.localhost/oauth2/callback"
11−cookie_domains=".oauth2-proxy.localhost" # Required so cookie can be read on all subdomains.
12−whitelist_domains=".oauth2-proxy.localhost" # Required to allow redirection back to original requested target.
10+redirect_url="http://oauth2-proxy.localtest.me/oauth2/callback"
11+cookie_domains=".localtest.me" # Required so cookie can be read on all subdomains.
12+whitelist_domains=".localtest.me" # Required to allow redirection back to original requested target.
1313
1414# Mandatory option when using oauth2-proxy with traefik
1515reverse_proxy="true"
16−# Required for traefik with ForwardAuth and static upstream configuration
16+# Required for traefik with ForwardAuth and static upstream configuration
1717upstreams="static://202"
1818# The following option skip the page requesting the user
1919# to click on a button to be redirected to the identity provider
contrib/local-environment/oauth2-proxy.cfg+2−2
@@ -2,7 +2,7 @@ http_address="0.0.0.0:4180"
22cookie_secret="OQINaROshtE9TcZkNAm-5Zs2Pv3xaWytBmc5W7sPX7w="
33email_domains="example.com"
44cookie_secure="false"
5−upstreams="http://httpbin.localtest.me:8080"
5+upstreams="http://httpbin"
66cookie_domains=[".localtest.me"] # Required so cookie can be read on all subdomains.
77whitelist_domains=[".localtest.me"] # Required to allow redirection back to original requested target.
88
@@ -11,6 +11,6 @@ client_secret="b2F1dGgyLXByb3h5LWNsaWVudC1zZWNyZXQK"
1111client_id="oauth2-proxy"
1212redirect_url="http://oauth2-proxy.localtest.me:4180/oauth2/callback"
1313
14−oidc_issuer_url="http://dex.localtest.me:4190/dex"
14+oidc_issuer_url="http://dex.localtest.me:5556/dex"
1515provider="oidc"
1616provider_display_name="Dex"
contrib/local-environment/traefik/dynamic.yaml+11−4
@@ -1,22 +1,25 @@
11http:
22 routers:
33 oauth2-proxy-route:
4− rule: "Host(`oauth2-proxy.oauth2-proxy.localhost`)"
4+ rule: "Host(`oauth2-proxy.localtest.me`)"
55 middlewares:
66 - auth-headers
77 service: oauth-backend
8+ dex-route:
9+ rule: "Host(`dex.localtest.me`)"
10+ service: dex-service
811 httpbin-route:
9− rule: "Host(`httpbin.oauth2-proxy.localhost`)"
12+ rule: "Host(`httpbin.localtest.me`)"
1013 service: httpbin-service
1114 middlewares:
1215 - oauth-auth-redirect # redirects all unauthenticated to oauth2 signin
1316 httpbin-route-2:
14− rule: "Host(`httpbin.oauth2-proxy.localhost`) && PathPrefix(`/no-auto-redirect`)"
17+ rule: "Host(`httpbin.localtest.me`) && PathPrefix(`/no-auto-redirect`)"
1518 service: httpbin-service
1619 middlewares:
1720 - oauth-auth-wo-redirect # unauthenticated session will return a 401
1821 services-oauth2-route:
19− rule: "Host(`httpbin.oauth2-proxy.localhost`) && PathPrefix(`/oauth2/`)"
22+ rule: "Host(`httpbin.localtest.me`) && PathPrefix(`/oauth2/`)"
2023 middlewares:
2124 - auth-headers
2225 service: oauth-backend
@@ -30,6 +33,10 @@ http:
3033 loadBalancer:
3134 servers:
3235 - url: http://oauth2-proxy:4180
36+ dex-service:
37+ loadBalancer:
38+ servers:
39+ - url: http://dex:5556
3340
3441 middlewares:
3542 auth-headers:
contrib/local-environment/traefik/traefik.yaml+2
@@ -5,3 +5,5 @@ log:
55providers:
66 file:
77 filename: /etc/traefik/dynamic.yaml
8+ # Routes are static for this example; disabling watch avoids host inotify limits.
9+ watch: false
contrib/oauth2-proxy.service.example+25−14
@@ -1,22 +1,33 @@
1−# Systemd service file for oauth2-proxy daemon
2−#
3−# Date: Feb 9, 2016
4−# Author: Srdjan Grubor <sgnn7@sgnn7.org>
5−
61[Unit]
72Description=oauth2-proxy daemon service
8−After=network.target
3+After=network.target network-online.target nss-lookup.target basic.target
4+Wants=network-online.target nss-lookup.target
5+StartLimitIntervalSec=30
6+StartLimitBurst=3
97
108[Service]
11−# www-data group and user need to be created before using these lines
12−User=www-data
13−Group=www-data
14−
15−ExecStart=/usr/local/bin/oauth2-proxy --config=/etc/oauth2-proxy.cfg
9+User=oauth2-proxy
10+Group=oauth2-proxy
11+Restart=on-failure
12+RestartSec=30
13+WorkingDirectory=/etc/oauth2-proxy
14+ExecStart=/usr/bin/oauth2-proxy --config=/etc/oauth2-proxy/oauth2-proxy.cfg
1615ExecReload=/bin/kill -HUP $MAINPID
17−
18−KillMode=process
19−Restart=always
16+LimitNOFILE=65535
17+NoNewPrivileges=true
18+ProtectHome=true
19+ProtectSystem=full
20+ProtectHostname=true
21+ProtectControlGroups=true
22+ProtectKernelModules=true
23+ProtectKernelTunables=true
24+LockPersonality=true
25+RestrictRealtime=yes
26+RestrictNamespaces=yes
27+MemoryDenyWriteExecute=yes
28+PrivateDevices=yes
29+PrivateTmp=true
30+CapabilityBoundingSet=
2031
2132[Install]
2233WantedBy=multi-user.target
dist.sh+11−3
@@ -16,6 +16,7 @@ ARCHS=(
1616 linux-armv6
1717 linux-armv7
1818 linux-ppc64le
19+ linux-s390x
1920 freebsd-amd64
2021 windows-amd64
2122)
@@ -29,16 +30,23 @@ for ARCH in "${ARCHS[@]}"; do
2930 GO_OS=$(echo $ARCH | awk -F- '{print $1}')
3031 GO_ARCH=$(echo $ARCH | awk -F- '{print $2}')
3132
33+ # Determine binary name based on OS
34+ if [[ "${GO_OS}" == "windows" ]]; then
35+ BINARY_NAME="${BINARY}.exe"
36+ else
37+ BINARY_NAME="${BINARY}"
38+ fi
39+
3240 # Create architecture specific binaries
3341 if [[ ${GO_ARCH} == armv* ]]; then
3442 GO_ARM=$(echo $GO_ARCH | awk -Fv '{print $2}')
3543 GO111MODULE=on GOOS=${GO_OS} GOARCH=arm GOARM=${GO_ARM} CGO_ENABLED=0 go build \
3644 -ldflags="-X github.com/oauth2-proxy/oauth2-proxy/v7/pkg/version.VERSION=${VERSION}" \
37− -o release/${BINARY}-${VERSION}.${ARCH}/${BINARY} .
45+ -o release/${BINARY}-${VERSION}.${ARCH}/${BINARY_NAME} .
3846 else
3947 GO111MODULE=on GOOS=${GO_OS} GOARCH=${GO_ARCH} CGO_ENABLED=0 go build \
4048 -ldflags="-X github.com/oauth2-proxy/oauth2-proxy/v7/pkg/version.VERSION=${VERSION}" \
41− -o release/${BINARY}-${VERSION}.${ARCH}/${BINARY} .
49+ -o release/${BINARY}-${VERSION}.${ARCH}/${BINARY_NAME} .
4250 fi
4351
4452 cd release
@@ -50,7 +58,7 @@ for ARCH in "${ARCHS[@]}"; do
5058 sha256sum ${BINARY}-${VERSION}.${ARCH}.tar.gz > ${BINARY}-${VERSION}.${ARCH}.tar.gz-sha256sum.txt
5159
5260 # Create sha256sum for architecture specific binary
53− sha256sum ${BINARY}-${VERSION}.${ARCH}/${BINARY} > ${BINARY}-${VERSION}.${ARCH}-sha256sum.txt
61+ sha256sum ${BINARY}-${VERSION}.${ARCH}/${BINARY_NAME} > ${BINARY}-${VERSION}.${ARCH}-sha256sum.txt
5462
5563 cd ..
5664done
docs/.gitignore+3
@@ -1,5 +1,8 @@
11# Dependencies
22/node_modules
3+package-lock.json
4+pnpm-lock.yaml
5+yarn.lock
36
47# Production
58/build
docs/README.md+1−1
@@ -19,7 +19,7 @@ This command starts a local development server and open up a browser window. Mos
1919## Build
2020
2121```console
22−npm build
22+npm run build
2323```
2424
2525This command generates static content into the `build` directory and can be served using any static contents hosting service.
docs/docs/behaviour.md+20−5
@@ -3,9 +3,24 @@ id: behaviour
33title: Behaviour
44---
55
6−1. Any request passing through the proxy (and not matched by `--skip-auth-regex`) is checked for the proxy's session cookie (`--cookie-name`) (or, if allowed, a JWT token - see `--skip-jwt-bearer-tokens`).
7−2. If authentication is required but missing then the user is asked to log in and redirected to the authentication provider (unless it is an Ajax request, i.e. one with `Accept: application/json`, in which case 401 Unauthorized is returned)
8−3. After returning from the authentication provider, the oauth tokens are stored in the configured session store (cookie, redis, ...) and a cookie is set
9−4. The request is forwarded to the upstream server with added user info and authentication headers (depending on the configuration)
6+1. Authentication Requirement: All requests passing through the proxy to upstream applications require authentication, excluding default proxy endpoints.
7+ - Exception: If the request matches a skipped route (configured via `--skip-auth-route`):
8+ - Authentication is not enforced, but the proxy will opportunistically attempt to validate a session cookie (`--cookie-name`) or JWT (`--skip-jwt-bearer-tokens`) if present in the request.
9+ - Configured user info and authentication headers (e.g., `--pass-access-token`) are injected to upstream routes when validation succeeds.
1010
11−Notice that the proxy also provides a number of useful [endpoints](features/endpoints.md).
11+2. Unauthenticated Requests: When authentication is missing but required, the user is redirected to the configured Identity Provider (IdP) login page by default.
12+ - Ajax Requests: If the request has `Accept: application/json` header:
13+ - Returns `401 Unauthorized`.
14+ - Invalid JWT Tokens: If `--skip-jwt-bearer-tokens` is set and the request includes an invalid JWT:
15+ - Redirects to the login page by default.
16+ - Returns `403 Forbidden` if `--bearer-token-login-fallback` is set to `false`.
17+
18+3. Post-Authentication: After successful authentication with the IdP, OAuth tokens are stored in the configured session store (cookie or Redis), and a cookie is set.
19+
20+4. Request Forwarding: The authenticated request is processed based on configuration:
21+ - Forwarded to the configured upstream application with added user info and authentication headers, or
22+ - Returns a valid status code for downstream processing by another proxy or load balancer (e.g., Nginx or Traefik).
23+
24+---
25+
26+Note: The proxy also provides a number of useful [endpoints](features/endpoints.md) for monitoring and management.
docs/docs/community/contribution.md+23−10
@@ -15,7 +15,9 @@ We suggest using [Visual Studio Code](https://code.visualstudio.com/docs/languag
1515
1616# Go version
1717
18−This project is currently still using go 1.19. You can follow the installation guide for go [here.](https://go.dev/doc/install) And you can find go version 1.19 in the archived section [here.](https://go.dev/dl/)
18+See the `go.mod` file in the root of this repository for the version of Go used by this project.
19+You can follow [the installation guide for Go](https://go.dev/doc/install),
20+and you can find this specific Go version on [the Go downloads page](https://go.dev/dl/).
1921
2022# Preparing your fork
2123Clone your fork, create a feature branch and update the depedencies to get started.
@@ -37,27 +39,27 @@ For starting oauth2-proxy locally open the debugging tab and create the `launch.
3739 "version": "0.2.0",
3840 "configurations": [
3941 {
40− "name": "Launch OAuth2-Proxy with Dex",
42+ "name": "Launch OAuth2 Proxy with Dex",
4143 "type": "go",
4244 "request": "launch",
4345 "mode": "auto",
4446 "program": "${workspaceFolder}",
4547 "args": [
4648 "--config",
47− // The following configuration contains settings for a locally deployed
49+ // The following configuration contains settings for a locally deployed
4850 // upstream and dex as an idetity provider
4951 "contrib/local-environment/oauth2-proxy.cfg"
5052 ]
5153 },
5254 {
53− "name": "Launch OAuth2-Proxy with Keycloak",
55+ "name": "Launch OAuth2 Proxy with Keycloak",
5456 "type": "go",
5557 "request": "launch",
5658 "mode": "auto",
5759 "program": "${workspaceFolder}",
5860 "args": [
5961 "--config",
60− // The following configuration contains settings for a locally deployed
62+ // The following configuration contains settings for a locally deployed
6163 // upstream and keycloak as an idetity provider
6264 "contrib/local-environment/oauth2-proxy-keycloak.cfg"
6365 ]
@@ -68,11 +70,22 @@ For starting oauth2-proxy locally open the debugging tab and create the `launch.
6870
6971Before you can start your local version of oauth2-proxy, you will have to use the provided docker compose files to start a local upstream service and identity provider. We suggest using [httpbin](https://hub.docker.com/r/kennethreitz/httpbin) as your upstream for testing as it allows for request and response introspection of all things HTTP.
7072
71−Open a terminal and switch to the `contrib/local-environment` directory.
73+Inside the `contrib/local-environment` directory you can use the `Makefile` for
74+starting different example setups:
7275
73−- Dex as your IdP: `docker compose -f docker-compose.yaml up dex etcd httpbin`
74−- Keycloak as your IdP: `docker compose -f docker-compose-keycloak.yaml up keycloak httpbin`
76+- Dex as your IdP: `make up` or `make down`
77+- Dex as your IdP using the alpha-config: `make alpha-config-up`
78+- Keycloak as your IdP: `make keycloak-up`
79+- Dex as your IdP & nginx reverse proxy: `make nginx-up`
80+- and many more...
7581
76−The username for both is `admin@example.com` and password is `password`.
82+Check out the `Makefile` to see what is available.
83+
84+The username and password for all setups is usually `admin@example.com` and `password`.
85+
86+The docker compose setups expose the services with a dynamic reverse DNS resolver: localtest.me
87+
88+- OAuth2 Proxy: http://oauth2-proxy.localtest.me:4180
89+- Upstream: http://httpbin.localtest.me:8080
90+- Dex: http://dex.localtest.me:5556
7791
78−Start oauth2-proxy from the debug tab and open http://oauth2-proxy.localtest.me:4180/ for testing.
docs/docs/community/security.md+1−1
@@ -21,7 +21,7 @@ any details publicly.
2121Security disclosures MUST be done in private.
2222If you have found an issue that you would like to bring to the attention of the
2323maintenance team for OAuth2 Proxy, please compose an email and send it to the
24−list of maintainers in our [MAINTAINERS](https://github.com/oauth2-proxy/oauth2-proxy/blob/master/MAINTAINERS) file.
24+list of maintainers in our [MAINTAINERS.md](https://github.com/oauth2-proxy/oauth2-proxy/blob/master/MAINTAINERS.md) file.
2525
2626Please include as much detail as possible.
2727Ideally, your disclosure should include:
docs/docs/configuration/alpha_config.md+198−31
@@ -24,17 +24,56 @@ When using alpha configuration, your config file will look something like below:
2424upstreams:
2525 - id: ...
2626 ...: ...
27−injectRequestHeaders:
28− - name: ...
27+providers:
28+ - id: ...
2929 ...: ...
30+cookie:
31+ secret: ...
32+ ...: ...
33+injectRequestHeaders:
34+ - secretSource:
35+ ...: ...
3036injectResponseHeaders:
31− - name: ...
32− ...: ...
37+ - claimSource:
38+ ...: ...
3339```
3440
3541Please browse the [reference](#configuration-reference) below for the structure
3642of the new configuration format.
3743
44+# Migration Guide
45+
46+This section details breaking changes and migration steps for moving to the new
47+alpha configuration format.
48+
49+## Migrating header injections in v7.14.0
50+
51+From v7.14.0 onward, header injection sources must be explicitly nested. If you
52+previously relied on squashed fields, update to the new structure before
53+upgrading:
54+
55+```yaml
56+# before v7.14.0
57+injectRequestHeaders:
58+- name: X-Forwarded-User
59+ values:
60+ - claim: user
61+- name: X-Custom-Secret-header
62+ values:
63+ - value: my-super-secret
64+
65+# v7.14.0 and later
66+injectRequestHeaders:
67+- name: X-Forwarded-User
68+ values:
69+ - claimSource:
70+ claim: user
71+- name: X-Custom-Secret-header
72+ values:
73+ - secretSource:
74+ value: my-super-secret
75+```
76+
3877## Using Alpha Configuration
3978
4079To use the new **alpha** configuration, generate a YAML file based on the format
@@ -67,9 +106,20 @@ the new config.
67106oauth2-proxy --alpha-config ./path/to/new/config.yaml --config ./path/to/existing/config.cfg
68107```
69108
70−## Using ENV variables in the alpha configuration
109+### Validating Alpha Configuration
110+
111+Use `--config-test` to validate your alpha configuration without starting the proxy:
112+
113+```bash
114+oauth2-proxy --config core.cfg --alpha-config alpha.yaml --config-test
115+```
116+
117+This is useful for CI/CD pipelines to catch configuration errors before deployment.
118+See the [Configuration Validation](./overview.md#configuration-validation) section for more details.
119+
120+### How to use environment variables
71121
72−The alpha package supports the use of environment variables in place of yaml keys, allowing sensitive values to be pulled from somewhere other than the yaml file.
122+The alpha package supports the use of environment variables in place of yaml values, allowing sensitive data to be pulled from somewhere other than the yaml file.
73123When using environment variables, your yaml will look like this:
74124
75125```yaml
@@ -81,6 +131,109 @@ When using environment variables, your yaml will look like this:
81131Where CLIENT_SECRET is an environment variable.
82132More information and available patterns can be found [here](https://github.com/a8m/envsubst#docs)
83133
134+### How to inject custom headers
135+
136+Configure `injectRequestHeaders` and `injectResponseHeaders` in alpha config YAML.
137+
138+```yaml
139+injectRequestHeaders:
140+ - name: "X-User-Email"
141+ values:
142+ - claimSource:
143+ claim: "email" # extract the email claim contents from the id token
144+ - name: "X-Static-Secret"
145+ values:
146+ # secrets need to be encoded with base64 when directly in the yaml config but will be send decoded
147+ - secretSource:
148+ value: "c3VwZXItc2VjcmV0"
149+ - name: "X-Static-File-Secret"
150+ - secretSource:
151+ fromFile: "/path/to/my/secret"
152+ - name: "X-Static-Env-Secret"
153+ - secretSource:
154+ value: "${MY_SECRET_ENV}" # content still needs to be base64 encoded
155+injectResponseHeaders:
156+ # Following will result in a header "Authorization: Basic <user:password> (encoded)"
157+ - name: "Authorization"
158+ values:
159+ - claimSource:
160+ claim: user
161+ prefix: "Basic "
162+ basicAuthPassword:
163+ value: c3VwZXItc2VjcmV0LXBhc3N3b3Jk # base64 encoded password
164+```
165+
166+**Value sources:**
167+* `claimSource` - `claim` (session claims either from id token or from profile URL)
168+* `secretSource` - `value` (base64), `fromFile` (file path)
169+
170+#### Claim value serialization
171+
172+`claimSource` converts the selected claim into one or more string header values. Scalars
173+produce one value, while arrays produce one value per element. Values that cannot be
174+converted directly to strings, such as objects, are JSON-encoded individually.
175+
176+Each non-empty value is added separately under the configured header name. An array of
177+objects therefore produces multiple header values containing one JSON object each, not a
178+single JSON array. HTTP libraries and intermediaries may expose repeated values as a
179+comma-joined string, so consumers should retrieve and parse each header value separately.
180+
181+**Request option:** `preserveRequestValue: true` retains existing header values
182+
183+**Incompatibility:** Remove legacy flags `pass-user-headers`, `set-xauthrequest`
184+
185+### How to utilize arbitrary claims provided by your Identity Provider
186+
187+With the additionalClaims attribute you can specify which claims you want to extract
188+from the ID Token or userinfo (ProfileURL) endpoint.
189+
190+Configure these on the relevant provider entry:
191+
192+```yaml
193+providers:
194+ - id: my-oidc-provider
195+ provider: oidc
196+ clientID: ${OAUTH_CLIENT_ID}
197+ clientSecret: ${OAUTH_CLIENT_SECRET}
198+ oidcConfig:
199+ issuerURL: https://issuer.example.com
200+ profileURL: https://issuer.example.com/oauth2/userinfo
201+ additionalClaims:
202+ - department
203+ - employee_id
204+ - organization.name
205+```
206+
207+OAuth2 Proxy resolves each configured claim using the following order:
208+
209+1. The raw ID token is checked first.
210+2. If the claim is not present there and `profileURL` is configured, the userinfo endpoint is queried.
211+3. If `skipClaimsFromProfileURL: true` is set, only the ID token is used.
212+
213+Claims that are not found are ignored rather than causing authentication to fail.
214+
215+You can use dot-separated paths for nested JSON objects, for example `organization.name`.
216+Array indexes are not supported.
217+
218+Once loaded, these claims are stored in the session as `additionalClaims`. They can then be
219+used anywhere session claims are accepted, including header injection:
220+
221+```yaml
222+injectRequestHeaders:
223+ - name: X-Department
224+ values:
225+ - claimSource:
226+ claim: department
227+ - name: X-Organization
228+ values:
229+ - claimSource:
230+ claim: organization.name
231+```
232+
233+This is useful when your IdP exposes application-specific attributes such as department,
234+tenant, employee ID, entitlement, or other custom claims that are not part of the default
235+OAuth2 Proxy session fields.
236+
84237## Removed options
85238
86239The following flags/options and their respective environment variables are no
@@ -168,7 +321,7 @@ They may change between releases without notice.
168321| `injectResponseHeaders` | _[[]Header](#header)_ | InjectResponseHeaders is used to configure headers that should be added<br/>to responses from the proxy.<br/>This is typically used when using the proxy as an external authentication<br/>provider in conjunction with another proxy such as NGINX and its<br/>auth_request module.<br/>Headers may source values from either the authenticated user's session<br/>or from a static secret value. |
169322| `server` | _[Server](#server)_ | Server is used to configure the HTTP(S) server for the proxy application.<br/>You may choose to run both HTTP and HTTPS servers simultaneously.<br/>This can be done by setting the BindAddress and the SecureBindAddress simultaneously.<br/>To use the secure server you must configure a TLS certificate and key. |
170323| `metricsServer` | _[Server](#server)_ | MetricsServer is used to configure the HTTP(S) server for metrics.<br/>You may choose to run both HTTP and HTTPS servers simultaneously.<br/>This can be done by setting the BindAddress and the SecureBindAddress simultaneously.<br/>To use the secure server you must configure a TLS certificate and key. |
171−| `providers` | _[Providers](#providers)_ | Providers is used to configure multiple providers. |
324+| `providers` | _[Providers](#providers)_ | Providers is used to configure your provider. **Multiple-providers is not<br/>yet working.** [This feature is tracked in<br/>#925](https://github.com/oauth2-proxy/oauth2-proxy/issues/926) |
172325
173326### AzureOptions
174327
@@ -200,20 +353,10 @@ ClaimSource allows loading a header value from a claim within the session
200353
201354| Field | Type | Description |
202355| ----- | ---- | ----------- |
203−| `claim` | _string_ | Claim is the name of the claim in the session that the value should be<br/>loaded from. |
356+| `claim` | _string_ | Claim is the name of the claim in the session that the value should be<br/>loaded from. Available claims: `access_token` `id_token` `created_at`<br/>`expires_on` `refresh_token` `email` `user` `groups` `preferred_username`. |
204357| `prefix` | _string_ | Prefix is an optional prefix that will be prepended to the value of the<br/>claim if it is non-empty. |
205358| `basicAuthPassword` | _[SecretSource](#secretsource)_ | BasicAuthPassword converts this claim into a basic auth header.<br/>Note the value of claim will become the basic auth username and the<br/>basicAuthPassword will be used as the password value. |
206359
207−### Duration
208−#### (`string` alias)
209−
210−(**Appears on:** [Upstream](#upstream))
211−
212−Duration is as string representation of a period of time.
213−A duration string is a is a possibly signed sequence of decimal numbers,
214−each with optional fraction and a unit suffix, such as "300ms", "-1.5h" or "2h45m".
215−Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
216−
217360### GitHubOptions
218361
219362(**Appears on:** [Provider](#provider))
@@ -252,6 +395,8 @@ Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
252395| `serviceAccountJson` | _string_ | ServiceAccountJSON is the path to the service account json credentials |
253396| `useApplicationDefaultCredentials` | _bool_ | UseApplicationDefaultCredentials is a boolean whether to use Application Default Credentials instead of a ServiceAccountJSON |
254397| `targetPrincipal` | _string_ | TargetPrincipal is the Google Service Account used for Application Default Credentials |
398+| `useOrganizationID` | _bool_ | UseOrganizationId indicates whether to use the organization ID as the UserName claim |
399+| `adminAPIUserScope` | _string_ | admin scope needed for fetching user organization information from admin api, can be one of cloud, user or defaults to readonly |
255400
256401### Header
257402
@@ -264,6 +409,7 @@ response header.
264409| ----- | ---- | ----------- |
265410| `name` | _string_ | Name is the header name to be used for this set of values.<br/>Names should be unique within a list of Headers. |
266411| `preserveRequestValue` | _bool_ | PreserveRequestValue determines whether any values for this header<br/>should be preserved for the request to the upstream server.<br/>This option only applies to injected request headers.<br/>Defaults to false (headers that match this header will be stripped). |
412+| `InsecureSkipHeaderNormalization` | _bool_ | InsecureSkipHeaderNormalization disables normalizing the header name<br/>According to RFC 7230 Section 3.2 there aren't any rules about<br/>capitalization of header names, but the standard practice is to use<br/>Title-Case (e.g. X-Forwarded-For). By default, header names will be<br/>normalized to Title-Case and any incoming headers that match will be<br/>treated as the same header. Additionally underscores (_) in header names<br/>will be converted to dashes (-) when normalizing.<br/>Defaults to false (header names will be normalized). |
267413| `values` | _[[]HeaderValue](#headervalue)_ | Values contains the desired values for this header |
268414
269415### HeaderValue
@@ -278,7 +424,7 @@ make up the header value
278424| `value` | _[]byte_ | Value expects a base64 encoded string value. |
279425| `fromEnv` | _string_ | FromEnv expects the name of an environment variable. |
280426| `fromFile` | _string_ | FromFile expects a path to a file containing the secret value. |
281−| `claim` | _string_ | Claim is the name of the claim in the session that the value should be<br/>loaded from. |
427+| `claim` | _string_ | Claim is the name of the claim in the session that the value should be<br/>loaded from. Available claims: `access_token` `id_token` `created_at`<br/>`expires_on` `refresh_token` `email` `user` `groups` `preferred_username`. |
282428| `prefix` | _string_ | Prefix is an optional prefix that will be prepended to the value of the<br/>claim if it is non-empty. |
283429| `basicAuthPassword` | _[SecretSource](#secretsource)_ | BasicAuthPassword converts this claim into a basic auth header.<br/>Note the value of claim will become the basic auth username and the<br/>basicAuthPassword will be used as the password value. |
284430
@@ -385,6 +531,17 @@ character.
385531| `default` | _[]string_ | _(Optional)_ Default specifies a default value or values that will be<br/>passed to the IdP if not overridden. |
386532| `allow` | _[[]URLParameterRule](#urlparameterrule)_ | _(Optional)_ Allow specifies rules about how the default (if any) may be<br/>overridden via the query string to `/oauth2/start`. Only<br/>values that match one or more of the allow rules will be<br/>forwarded to the IdP. |
387533
534+### MicrosoftEntraIDOptions
535+
536+(**Appears on:** [Provider](#provider))
537+
538+
539+
540+| Field | Type | Description |
541+| ----- | ---- | ----------- |
542+| `allowedTenants` | _[]string_ | AllowedTenants is a list of allowed tenants. In case of multi-tenant apps, incoming tokens are<br/>issued by different issuers and OIDC issuer verification needs to be disabled.<br/>When not specified, all tenants are allowed. Redundant for single-tenant apps<br/>(regular ID token validation matches the issuer). |
543+| `federatedTokenAuth` | _bool_ | FederatedTokenAuth enable oAuth2 client authentication with federated token projected<br/>by Entra Workload Identity plugin, instead of client secret. |
544+
388545### OIDCOptions
389546
390547(**Appears on:** [Provider](#provider))
@@ -399,11 +556,13 @@ character.
399556| `insecureSkipNonce` | _bool_ | InsecureSkipNonce skips verifying the ID Token's nonce claim that must match<br/>the random nonce sent in the initial OAuth flow. Otherwise, the nonce is checked<br/>after the initial OAuth redeem & subsequent token refreshes.<br/>default set to 'true'<br/>Warning: In a future release, this will change to 'false' by default for enhanced security. |
400557| `skipDiscovery` | _bool_ | SkipDiscovery allows to skip OIDC discovery and use manually supplied Endpoints<br/>default set to 'false' |
401558| `jwksURL` | _string_ | JwksURL is the OpenID Connect JWKS URL<br/>eg: https://www.googleapis.com/oauth2/v3/certs |
559+| `publicKeyFiles` | _[]string_ | PublicKeyFiles is a list of paths pointing to public key files in PEM format to use<br/>for verifying JWT tokens |
402560| `emailClaim` | _string_ | EmailClaim indicates which claim contains the user email,<br/>default set to 'email' |
403561| `groupsClaim` | _string_ | GroupsClaim indicates which claim contains the user groups<br/>default set to 'groups' |
404562| `userIDClaim` | _string_ | UserIDClaim indicates which claim contains the user ID<br/>default set to 'email' |
405563| `audienceClaims` | _[]string_ | AudienceClaim allows to define any claim that is verified against the client id<br/>By default `aud` claim is used for verification. |
406564| `extraAudiences` | _[]string_ | ExtraAudiences is a list of additional audiences that are allowed<br/>to pass verification in addition to the client id. |
565+| `enabledSigningAlgs` | _[]string_ | EnabledSigningAlgs is a list of allowed JWT signing algorithms.<br/>When discovery is enabled, the effective set is the intersection<br/>between this list and the provider's discovered supported algorithms.<br/>By default `RS256` is used if nothing has been discovered or specified. |
407566
408567### Provider
409568
@@ -418,6 +577,7 @@ Provider holds all configuration for a single provider
418577| `clientSecretFile` | _string_ | ClientSecretFile is the name of the file<br/>containing the OAuth Client Secret, it will be used if ClientSecret is not set. |
419578| `keycloakConfig` | _[KeycloakOptions](#keycloakoptions)_ | KeycloakConfig holds all configurations for Keycloak provider. |
420579| `azureConfig` | _[AzureOptions](#azureoptions)_ | AzureConfig holds all configurations for Azure provider. |
580+| `microsoftEntraIDConfig` | _[MicrosoftEntraIDOptions](#microsoftentraidoptions)_ | MicrosoftEntraIDConfig holds all configurations for Entra ID provider. |
421581| `ADFSConfig` | _[ADFSOptions](#adfsoptions)_ | ADFSConfig holds all configurations for ADFS provider. |
422582| `bitbucketConfig` | _[BitbucketOptions](#bitbucketoptions)_ | BitbucketConfig holds all configurations for Bitbucket provider. |
423583| `githubConfig` | _[GitHubOptions](#githuboptions)_ | GitHubConfig holds all configurations for GitHubC provider. |
@@ -432,6 +592,7 @@ Provider holds all configuration for a single provider
432592| `useSystemTrustStore` | _bool_ | UseSystemTrustStore determines if your custom CA files and the system trust store are used<br/>If set to true, your custom CA files and the system trust store are used otherwise only your custom CA files. |
433593| `loginURL` | _string_ | LoginURL is the authentication endpoint |
434594| `loginURLParameters` | _[[]LoginURLParameter](#loginurlparameter)_ | LoginURLParameters defines the parameters that can be passed from the start URL to the IdP login URL |
595+| `authRequestResponseMode` | _string_ | AuthRequestResponseMode defines the response mode to request during authorization request |
435596| `redeemURL` | _string_ | RedeemURL is the token redemption endpoint |
436597| `profileURL` | _string_ | ProfileURL is the profile access endpoint |
437598| `skipClaimsFromProfileURL` | _bool_ | SkipClaimsFromProfileURL allows to skip request to Profile URL for resolving claims not present in id_token<br/>default set to 'false' |
@@ -440,6 +601,7 @@ Provider holds all configuration for a single provider
440601| `scope` | _string_ | Scope is the OAuth scope specification |
441602| `allowedGroups` | _[]string_ | AllowedGroups is a list of restrict logins to members of this group |
442603| `code_challenge_method` | _string_ | The code challenge method |
604+| `additionalClaims` | _[]string_ | Additional claims to be obtained from the upstream IDP, either from the id_token or from the userinfo endpoint if configured. |
443605| `backendLogoutURL` | _string_ | URL to call to perform backend logout, `{id_token}` would be replaced by the actual `id_token` if available in the session |
444606
445607### ProviderType
@@ -458,7 +620,11 @@ and oidc.
458620
459621(**Appears on:** [AlphaOptions](#alphaoptions))
460622
461−Providers is a collection of definitions for providers.
623+The provider can be selected using the `provider` configuration value, or
624+set in the [`providers` array using
625+AlphaConfig](https://oauth2-proxy.github.io/oauth2-proxy/configuration/alpha-config#providers).
626+However, [**the feature to implement multiple providers is not
627+complete**](https://github.com/oauth2-proxy/oauth2-proxy/issues/926).
462628
463629### SecretSource
464630
@@ -481,9 +647,9 @@ Server represents the configuration for an HTTP(S) server
481647
482648| Field | Type | Description |
483649| ----- | ---- | ----------- |
484−| `BindAddress` | _string_ | BindAddress is the address on which to serve traffic.<br/>Leave blank or set to "-" to disable. |
485−| `SecureBindAddress` | _string_ | SecureBindAddress is the address on which to serve secure traffic.<br/>Leave blank or set to "-" to disable. |
486−| `TLS` | _[TLS](#tls)_ | TLS contains the information for loading the certificate and key for the<br/>secure traffic and further configuration for the TLS server. |
650+| `bindAddress` | _string_ | BindAddress is the address on which to serve traffic.<br/>Different types of bind addresses are supported:<br/>* `[http://]<addr>:<port>`<br/>* `fd:<int>` (case insensitive)<br/>* `unix://<path>`<br/>Unix sockets are created with default system umask mode, which can be overridden, e.g.: `unix://my-socket,mode=0777`<br/>Square brackets are required for ipv6 address, e.g. `http://[::1]:4180`<br/>Leave blank or set to "-" to disable. |
651+| `secureBindAddress` | _string_ | SecureBindAddress is the address on which to serve secure traffic.<br/>Secure bind addresses need to respond with valid SSL and use the following format:<br/>* `[https://]<addr>:<port>`<br/>Square brackets are required for ipv6 address, e.g. `https://[::1]:4180`<br/>Leave blank or set to "-" to disable. |
652+| `tls` | _[TLS](#tls)_ | TLS contains the information for loading the certificate and key for the<br/>secure traffic and further configuration for the TLS server. |
487653
488654### TLS
489655
@@ -494,10 +660,10 @@ as well as an optional minimal TLS version that is acceptable.
494660
495661| Field | Type | Description |
496662| ----- | ---- | ----------- |
497−| `Key` | _[SecretSource](#secretsource)_ | Key is the TLS key data to use.<br/>Typically this will come from a file. |
498−| `Cert` | _[SecretSource](#secretsource)_ | Cert is the TLS certificate data to use.<br/>Typically this will come from a file. |
499−| `MinVersion` | _string_ | MinVersion is the minimal TLS version that is acceptable.<br/>E.g. Set to "TLS1.3" to select TLS version 1.3 |
500−| `CipherSuites` | _[]string_ | CipherSuites is a list of TLS cipher suites that are allowed.<br/>E.g.:<br/>- TLS_RSA_WITH_RC4_128_SHA<br/>- TLS_RSA_WITH_AES_256_GCM_SHA384<br/>If not specified, the default Go safe cipher list is used.<br/>List of valid cipher suites can be found in the [crypto/tls documentation](https://pkg.go.dev/crypto/tls#pkg-constants). |
663+| `key` | _[SecretSource](#secretsource)_ | Key is the TLS key data to use.<br/>Typically this will come from a file. |
664+| `cert` | _[SecretSource](#secretsource)_ | Cert is the TLS certificate data to use.<br/>Typically this will come from a file. |
665+| `minVersion` | _string_ | MinVersion is the minimal TLS version that is acceptable.<br/>E.g. Set to "TLS1.3" to select TLS version 1.3 |
666+| `cipherSuites` | _[]string_ | CipherSuites is a list of TLS cipher suites that are allowed.<br/>E.g.:<br/>- TLS_RSA_WITH_RC4_128_SHA<br/>- TLS_RSA_WITH_AES_256_GCM_SHA384<br/>If not specified, the default Go safe cipher list is used.<br/>List of valid cipher suites can be found in the [crypto/tls documentation](https://pkg.go.dev/crypto/tls#pkg-constants). |
501667
502668### URLParameterRule
503669
@@ -523,16 +689,17 @@ Requests will be proxied to this upstream if the path matches the request path.
523689| Field | Type | Description |
524690| ----- | ---- | ----------- |
525691| `id` | _string_ | ID should be a unique identifier for the upstream.<br/>This value is required for all upstreams. |
526−| `path` | _string_ | Path is used to map requests to the upstream server.<br/>The closest match will take precedence and all Paths must be unique.<br/>Path can also take a pattern when used with RewriteTarget.<br/>Path segments can be captured and matched using regular experessions.<br/>Eg:<br/>- `^/foo$`: Match only the explicit path `/foo`<br/>- `^/bar/$`: Match any path prefixed with `/bar/`<br/>- `^/baz/(.*)$`: Match any path prefixed with `/baz` and capture the remaining path for use with RewriteTarget |
527−| `rewriteTarget` | _string_ | RewriteTarget allows users to rewrite the request path before it is sent to<br/>the upstream server.<br/>Use the Path to capture segments for reuse within the rewrite target.<br/>Eg: With a Path of `^/baz/(.*)`, a RewriteTarget of `/foo/$1` would rewrite<br/>the request `/baz/abc/123` to `/foo/abc/123` before proxying to the<br/>upstream server. |
692+| `path` | _string_ | Path is used to map requests to the upstream server.<br/>The closest match will take precedence and all Paths must be unique.<br/>Without RewriteTarget, Path follows gorilla/mux route syntax.<br/>Eg:<br/>- `/foo`: Match only the explicit path `/foo`<br/>- `/bar/`: Match any path prefixed with `/bar/`<br/>- `/baz/{path:.*}`: Match any path prefixed with `/baz/`<br/>When RewriteTarget is set, Path is treated as a regular expression.<br/>Eg: `^/baz/(.*)$` matches any path prefixed with `/baz` and captures the<br/>remaining path for use with RewriteTarget. |
693+| `rewriteTarget` | _string_ | RewriteTarget allows users to rewrite the request path before it is sent to<br/>the upstream server (for an HTTP/HTTPS upstream) or mapped to the filesystem<br/>(for a `file:` upstream).<br/>Use the Path to capture segments for reuse within the rewrite target.<br/>Eg: With a Path of `^/baz/(.*)`, a RewriteTarget of `/foo/$1` would rewrite<br/>the request `/baz/abc/123` to `/foo/abc/123` before proxying to the<br/>upstream server. Or if the upstream were `file:///app`, a request for<br/>`/baz/info.html` would return the contents of the file `/app/foo/info.html`. |
528694| `uri` | _string_ | The URI of the upstream server. This may be an HTTP(S) server of a File<br/>based URL. It may include a path, in which case all requests will be served<br/>under that path.<br/>Eg:<br/>- http://localhost:8080<br/>- https://service.localhost<br/>- https://service.localhost/path<br/>- file://host/path<br/>If the URI's path is "/base" and the incoming request was for "/dir",<br/>the upstream request will be for "/base/dir". |
529695| `insecureSkipTLSVerify` | _bool_ | InsecureSkipTLSVerify will skip TLS verification of upstream HTTPS hosts.<br/>This option is insecure and will allow potential Man-In-The-Middle attacks<br/>between OAuth2 Proxy and the upstream server.<br/>Defaults to false. |
530696| `static` | _bool_ | Static will make all requests to this upstream have a static response.<br/>The response will have a body of "Authenticated" and a response code<br/>matching StaticCode.<br/>If StaticCode is not set, the response will return a 200 response. |
531697| `staticCode` | _int_ | StaticCode determines the response code for the Static response.<br/>This option can only be used with Static enabled. |
532−| `flushInterval` | _[Duration](#duration)_ | FlushInterval is the period between flushing the response buffer when<br/>streaming response from the upstream.<br/>Defaults to 1 second. |
698+| `flushInterval` | _duration_ | FlushInterval is the period between flushing the response buffer when<br/>streaming response from the upstream.<br/>Defaults to 1 second. |
533699| `passHostHeader` | _bool_ | PassHostHeader determines whether the request host header should be proxied<br/>to the upstream server.<br/>Defaults to true. |
534700| `proxyWebSockets` | _bool_ | ProxyWebSockets enables proxying of websockets to upstream servers<br/>Defaults to true. |
535−| `timeout` | _[Duration](#duration)_ | Timeout is the maximum duration the server will wait for a response from the upstream server.<br/>Defaults to 30 seconds. |
701+| `timeout` | _duration_ | Timeout is the maximum duration the server will wait for a response from the upstream server.<br/>Defaults to 30 seconds. |
702+| `disableKeepAlives` | _bool_ | DisableKeepAlives disables HTTP keep-alive connections to the upstream server.<br/>Defaults to false. |
536703
537704### UpstreamConfig
538705
docs/docs/configuration/alpha_config.md.tmpl+159−6
@@ -24,17 +24,56 @@ When using alpha configuration, your config file will look something like below:
2424upstreams:
2525 - id: ...
2626 ...: ...
27−injectRequestHeaders:
28− - name: ...
27+providers:
28+ - id: ...
2929 ...: ...
30+cookie:
31+ secret: ...
32+ ...: ...
33+injectRequestHeaders:
34+ - secretSource:
35+ ...: ...
3036injectResponseHeaders:
31− - name: ...
32− ...: ...
37+ - claimSource:
38+ ...: ...
3339```
3440
3541Please browse the [reference](#configuration-reference) below for the structure
3642of the new configuration format.
3743
44+# Migration Guide
45+
46+This section details breaking changes and migration steps for moving to the new
47+alpha configuration format.
48+
49+## Migrating header injections in v7.14.0
50+
51+From v7.14.0 onward, header injection sources must be explicitly nested. If you
52+previously relied on squashed fields, update to the new structure before
53+upgrading:
54+
55+```yaml
56+# before v7.14.0
57+injectRequestHeaders:
58+- name: X-Forwarded-User
59+ values:
60+ - claim: user
61+- name: X-Custom-Secret-header
62+ values:
63+ - value: my-super-secret
64+
65+# v7.14.0 and later
66+injectRequestHeaders:
67+- name: X-Forwarded-User
68+ values:
69+ - claimSource:
70+ claim: user
71+- name: X-Custom-Secret-header
72+ values:
73+ - secretSource:
74+ value: my-super-secret
75+```
76+
3877## Using Alpha Configuration
3978
4079To use the new **alpha** configuration, generate a YAML file based on the format
@@ -67,9 +106,20 @@ the new config.
67106oauth2-proxy --alpha-config ./path/to/new/config.yaml --config ./path/to/existing/config.cfg
68107```
69108
70−## Using ENV variables in the alpha configuration
109+### Validating Alpha Configuration
110+
111+Use `--config-test` to validate your alpha configuration without starting the proxy:
112+
113+```bash
114+oauth2-proxy --config core.cfg --alpha-config alpha.yaml --config-test
115+```
116+
117+This is useful for CI/CD pipelines to catch configuration errors before deployment.
118+See the [Configuration Validation](./overview.md#configuration-validation) section for more details.
71119
72−The alpha package supports the use of environment variables in place of yaml keys, allowing sensitive values to be pulled from somewhere other than the yaml file.
120+### How to use environment variables
121+
122+The alpha package supports the use of environment variables in place of yaml values, allowing sensitive data to be pulled from somewhere other than the yaml file.
73123When using environment variables, your yaml will look like this:
74124
75125```yaml
@@ -81,6 +131,109 @@ When using environment variables, your yaml will look like this:
81131Where CLIENT_SECRET is an environment variable.
82132More information and available patterns can be found [here](https://github.com/a8m/envsubst#docs)
83133
134+### How to inject custom headers
135+
136+Configure `injectRequestHeaders` and `injectResponseHeaders` in alpha config YAML.
137+
138+```yaml
139+injectRequestHeaders:
140+ - name: "X-User-Email"
141+ values:
142+ - claimSource:
143+ claim: "email" # extract the email claim contents from the id token
144+ - name: "X-Static-Secret"
145+ values:
146+ # secrets need to be encoded with base64 when directly in the yaml config but will be send decoded
147+ - secretSource:
148+ value: "c3VwZXItc2VjcmV0"
149+ - name: "X-Static-File-Secret"
150+ - secretSource:
151+ fromFile: "/path/to/my/secret"
152+ - name: "X-Static-Env-Secret"
153+ - secretSource:
154+ value: "${MY_SECRET_ENV}" # content still needs to be base64 encoded
155+injectResponseHeaders:
156+ # Following will result in a header "Authorization: Basic <user:password> (encoded)"
157+ - name: "Authorization"
158+ values:
159+ - claimSource:
160+ claim: user
161+ prefix: "Basic "
162+ basicAuthPassword:
163+ value: c3VwZXItc2VjcmV0LXBhc3N3b3Jk # base64 encoded password
164+```
165+
166+**Value sources:**
167+* `claimSource` - `claim` (session claims either from id token or from profile URL)
168+* `secretSource` - `value` (base64), `fromFile` (file path)
169+
170+#### Claim value serialization
171+
172+`claimSource` converts the selected claim into one or more string header values. Scalars
173+produce one value, while arrays produce one value per element. Values that cannot be
174+converted directly to strings, such as objects, are JSON-encoded individually.
175+
176+Each non-empty value is added separately under the configured header name. An array of
177+objects therefore produces multiple header values containing one JSON object each, not a
178+single JSON array. HTTP libraries and intermediaries may expose repeated values as a
179+comma-joined string, so consumers should retrieve and parse each header value separately.
180+
181+**Request option:** `preserveRequestValue: true` retains existing header values
182+
183+**Incompatibility:** Remove legacy flags `pass-user-headers`, `set-xauthrequest`
184+
185+### How to utilize arbitrary claims provided by your Identity Provider
186+
187+With the additionalClaims attribute you can specify which claims you want to extract
188+from the ID Token or userinfo (ProfileURL) endpoint.
189+
190+Configure these on the relevant provider entry:
191+
192+```yaml
193+providers:
194+ - id: my-oidc-provider
195+ provider: oidc
196+ clientID: ${OAUTH_CLIENT_ID}
197+ clientSecret: ${OAUTH_CLIENT_SECRET}
198+ oidcConfig:
199+ issuerURL: https://issuer.example.com
200+ profileURL: https://issuer.example.com/oauth2/userinfo
201+ additionalClaims:
202+ - department
203+ - employee_id
204+ - organization.name
205+```
206+
207+OAuth2 Proxy resolves each configured claim using the following order:
208+
209+1. The raw ID token is checked first.
210+2. If the claim is not present there and `profileURL` is configured, the userinfo endpoint is queried.
211+3. If `skipClaimsFromProfileURL: true` is set, only the ID token is used.
212+
213+Claims that are not found are ignored rather than causing authentication to fail.
214+
215+You can use dot-separated paths for nested JSON objects, for example `organization.name`.
216+Array indexes are not supported.
217+
218+Once loaded, these claims are stored in the session as `additionalClaims`. They can then be
219+used anywhere session claims are accepted, including header injection:
220+
221+```yaml
222+injectRequestHeaders:
223+ - name: X-Department
224+ values:
225+ - claimSource:
226+ claim: department
227+ - name: X-Organization
228+ values:
229+ - claimSource:
230+ claim: organization.name
231+```
232+
233+This is useful when your IdP exposes application-specific attributes such as department,
234+tenant, employee ID, entitlement, or other custom claims that are not part of the default
235+OAuth2 Proxy session fields.
236+
84237## Removed options
85238
86239The following flags/options and their respective environment variables are no
docs/docs/configuration/integrations/caddy.mdnew file+63
@@ -0,0 +1,63 @@
1+---
2+id: caddy
3+title: Caddy
4+---
5+
6+Integrate OAuth2 Proxy with Caddy v2 using the `forward_auth` directive.
7+
8+**Key features:**
9+- Simple forward_auth setup
10+- Automatic header handling
11+- Custom error handling and redirects
12+
13+## Configuring for use with the Caddy (v2) `forward_auth` directive
14+
15+The [Caddy `forward_auth` directive](https://caddyserver.com/docs/caddyfile/directives/forward_auth) allows Caddy to authenticate requests via the `oauth2-proxy`'s `/auth`.
16+
17+This example is for a simple reverse proxy setup where the `/oauth2/` path is kept under the same domain and failed auth requests (401 status returned) will be caught and redirected to the `sign_in` endpoint.
18+
19+**Following options need to be set on `oauth2-proxy`:**
20+- `--reverse-proxy=true`: Enables the use of `X-Forwarded-*` headers to determine redirects correctly
21+
22+```nginx title="Caddyfile"
23+example.com {
24+ # Requests to /oauth2/* are proxied to oauth2-proxy without authentication.
25+ # You can't use `reverse_proxy /oauth2/* oauth2-proxy.internal:4180` here because the reverse_proxy directive has lower precedence than the handle directive.
26+ handle /oauth2/* {
27+ reverse_proxy oauth2-proxy.internal:4180 {
28+ # oauth2-proxy requires the X-Real-IP and X-Forwarded-{Proto,Host,Uri} headers.
29+ # The reverse_proxy directive automatically sets X-Forwarded-{For,Proto,Host} headers.
30+ header_up X-Real-IP {remote_host}
31+ header_up X-Forwarded-Uri {uri}
32+ }
33+ }
34+
35+ # Requests to other paths are first processed by oauth2-proxy for authentication.
36+ handle {
37+ forward_auth oauth2-proxy.internal:4180 {
38+ uri /oauth2/auth
39+
40+ # oauth2-proxy requires the X-Real-IP and X-Forwarded-{Proto,Host,Uri} headers.
41+ # The forward_auth directive automatically sets the X-Forwarded-{For,Proto,Host,Method,Uri} headers.
42+ header_up X-Real-IP {remote_host}
43+
44+ # If needed, you can copy headers from the oauth2-proxy response to the request sent to the upstream.
45+ # Make sure to configure the --set-xauthrequest flag to enable this feature.
46+ #copy_headers X-Auth-Request-User X-Auth-Request-Email
47+
48+ # If oauth2-proxy returns a 401 status, redirect the client to the sign-in page.
49+ @error status 401
50+ handle_response @error {
51+ redir * /oauth2/sign_in?rd={scheme}://{host}{uri}
52+ }
53+ }
54+
55+ # If oauth2-proxy returns a 2xx status, the request is then proxied to the upstream.
56+ reverse_proxy upstream.internal:3000
57+ }
58+}
59+```
60+
61+:::note
62+If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
63+:::
docs/docs/configuration/integrations/headlamp.mdnew file+105
@@ -0,0 +1,105 @@
1+---
2+id: headlamp
3+title: Headlamp
4+---
5+
6+Modern, actively maintained Kubernetes web UI with OAuth2 Proxy integration examples.
7+
8+**Key features:**
9+- Active development and maintenance
10+- Modern, intuitive interface
11+- Multi-cluster support
12+- Plugin system
13+- Works with all OAuth2 providers
14+
15+## Configuring for use with Headlamp
16+
17+[Headlamp](https://headlamp.dev/) is a modern, user-friendly Kubernetes web UI that can be integrated with OAuth2 Proxy for authentication. This is a recommended alternative to the deprecated Kubernetes Dashboard.
18+
19+### Architecture
20+
21+```
22+User → Ingress → OAuth2 Proxy → Authentication Provider (e.g., Azure Entra ID)
23+ ↓
24+ Headlamp
25+```
26+
27+### Prerequisites
28+
29+- Kubernetes cluster (e.g., AKS, EKS, GKE, or self-hosted)
30+- Headlamp installed in the cluster
31+- OAuth2 provider configured (Azure Entra ID, Google, GitHub, etc.)
32+- Ingress controller (Nginx, Traefik, etc.)
33+
34+### Configuration Overview
35+
36+When integrating Headlamp with OAuth2 Proxy, the OAuth2 Proxy acts as a reverse proxy in front of Headlamp:
37+
38+1. User requests access to Headlamp
39+2. Ingress forwards to OAuth2 Proxy
40+3. OAuth2 Proxy authenticates the user via the OAuth2 provider
41+4. After successful authentication, OAuth2 Proxy proxies requests to Headlamp
42+5. Headlamp receives the authenticated user information via headers
43+
44+### OAuth2 Proxy Configuration
45+
46+Configure OAuth2 Proxy to proxy to the Headlamp service:
47+
48+```yaml
49+upstreamConfig:
50+ upstreams:
51+ - id: headlamp
52+ path: /
53+ uri: http://headlamp-service.headlamp-namespace.svc.cluster.local:4466
54+```
55+
56+Enable the necessary headers:
57+
58+```yaml
59+extraArgs:
60+ reverse-proxy: true
61+ pass-authorization-header: true
62+ set-xauthrequest: true
63+ email-domain: "*" # Or restrict to your organization
64+```
65+
66+### Example with Azure Entra ID on AKS
67+
68+For detailed instructions on deploying Headlamp with OAuth2 Proxy on Azure Kubernetes Service using Azure Entra ID, see the official Headlamp documentation:
69+
70+https://headlamp.dev/docs/latest/installation/in-cluster/aks-cluster-oauth/
71+
72+Key steps include:
73+
74+1. **Set up AKS with OIDC**: Enable Microsoft Entra ID authentication with Kubernetes RBAC
75+2. **Create Azure App Registration**: Configure redirect URI and create client secret
76+3. **Deploy Headlamp**: Install Headlamp via Helm in your cluster
77+4. **Deploy OAuth2 Proxy**: Configure OAuth2 Proxy with Entra ID provider settings and upstream pointing to Headlamp
78+5. **Configure Ingress**: Set up Ingress to route traffic through OAuth2 Proxy to Headlamp
79+6. **Set RBAC Policies**: Apply Kubernetes RBAC bindings based on users or groups
80+
81+### Integration with Other Providers
82+
83+The same integration pattern works with other OAuth2 providers supported by OAuth2 Proxy:
84+
85+- **Google**: Use the Google provider configuration
86+- **GitHub**: Use the GitHub provider configuration
87+- **GitLab**: Use the GitLab provider configuration
88+- **Keycloak**: Use the Keycloak OIDC provider configuration
89+- **Any OIDC Provider**: Use the generic OIDC provider configuration
90+
91+For provider-specific configuration examples, see the [OAuth Provider Configuration](../providers/index.md) documentation.
92+
93+### Benefits Over Kubernetes Dashboard
94+
95+Headlamp offers several advantages:
96+
97+- **Active Development**: Headlamp is actively maintained and developed
98+- **Modern UI**: Clean, intuitive interface with better UX
99+- **Plugin System**: Extensible with custom plugins
100+- **Multi-cluster Support**: Built-in support for managing multiple clusters
101+- **Desktop App**: Available as both web UI and desktop application
102+
103+:::note
104+If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
105+:::
docs/docs/configuration/integrations/index.mdnew file+41
@@ -0,0 +1,41 @@
1+---
2+id: index
3+title: Integrations
4+---
5+
6+This section provides configuration examples for integrating OAuth2 Proxy with various reverse proxies, ingress controllers, and Kubernetes web UIs.
7+
8+## Reverse Proxies and Ingress Controllers
9+
10+OAuth2 Proxy can be integrated with popular reverse proxies and ingress controllers to add authentication to your applications:
11+
12+- [Nginx](nginx.md)
13+- [Traefik](traefik.md)
14+- [caddy](caddy.md)
15+
16+## Kubernetes Web UIs
17+
18+OAuth2 Proxy can also be used to add authentication to Kubernetes web user interfaces:
19+
20+- [Headlamp](headlamp.md) ✨ *Recommended*
21+- [Kubernetes Dashboard](kubernetes-dashboard.md) ⚠️ *Deprecated*
22+
23+:::tip
24+When integrating with Kubernetes web UIs, make sure to:
25+1. Configure the Ingress to pass the Authorization header with the bearer token
26+2. Increase buffer sizes for large OIDC tokens (especially with Azure Entra ID)
27+3. Set up appropriate Kubernetes RBAC permissions for your users or groups
28+:::
29+
30+## General Requirements
31+
32+Most integrations require the following OAuth2 Proxy configuration:
33+
34+- `--reverse-proxy=true`: Required to correctly handle `X-Forwarded-*` headers
35+- **Session storage**: For production deployments with large tokens due to a lot of claims like AD groups, use `--session-store-type=redis`
36+
37+For provider-specific configuration, see the [OAuth Provider Configuration](../providers/index.md) documentation.
38+
39+:::note
40+If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
41+:::
docs/docs/configuration/integrations/kubernetes-dashboard.mdnew file+289
@@ -0,0 +1,289 @@
1+---
2+id: kubernetes-dashboard
3+title: Kubernetes Dashboard
4+---
5+
6+:::warning Deprecated Project
7+Kubernetes Dashboard has been deprecated and discontinued as of January 2025. See the [official announcement](https://github.com/kubernetes/dashboard/commit/0ba796dce6916bb6ca5da5ca0b3ab22cecfd1e18) for more information.
8+
9+You may want to consider alternative solutions such as [Headlamp](./headlamp.md).
10+:::
11+
12+## Kubernetes Dashboard on AKS with Azure Entra ID
13+
14+Integration guide for the deprecated Kubernetes Dashboard, including comprehensive Azure Entra ID configuration on AKS with detailed troubleshooting and RBAC setup.
15+
16+### Architecture
17+
18+```
19+User → Nginx Ingress → OAuth2 Proxy → Entra ID
20+ ↓
21+ Kubernetes Dashboard
22+```
23+
24+The integration flow:
25+1. Unauthenticated requests to Dashboard are intercepted by Nginx Ingress
26+2. Nginx redirects to OAuth2 Proxy for authentication
27+3. OAuth2 Proxy redirects to Entra ID login
28+4. After successful authentication, OAuth2 Proxy receives ID token from Entra ID
29+5. OAuth2 Proxy sets Authorization header with the bearer token
30+6. Nginx forwards the request with token to Kubernetes Dashboard
31+7. Dashboard validates the token and grants access based on AKS RBAC configuration
32+
33+### Prerequisites
34+
35+- AKS cluster with Entra ID integration enabled
36+- Kubernetes Dashboard installed (version 7.x or later)
37+- NGINX Ingress Controller installed
38+- Entra ID App Registration configured with:
39+ - Redirect URI: `https://your-oauth2-domain.com/oauth2/callback`
40+ - API Permissions: `openid`, `email`, `profile`
41+ - Groups claim enabled (if using group-based RBAC)
42+- Users or groups assigned appropriate Kubernetes RBAC permissions
43+
44+### Alpha Configuration Example
45+
46+Using [Alpha Configuration](../alpha_config.md) with the OAuth2 Proxy Helm chart:
47+
48+```yaml
49+alphaConfig:
50+ enabled: true
51+ configData:
52+ providers:
53+ - id: azure-entra
54+ provider: entra-id
55+ clientID: YOUR_CLIENT_ID
56+ clientSecret: YOUR_CLIENT_SECRET
57+ oidcConfig:
58+ issuerURL: https://login.microsoftonline.com/YOUR_TENANT_ID/v2.0
59+ audienceClaims:
60+ - aud
61+ emailClaim: email
62+ groupsClaim: groups
63+ userIDClaim: oid
64+ scope: openid email profile
65+
66+ upstreamConfig:
67+ upstreams:
68+ - id: static
69+ path: /
70+ static: true
71+ staticCode: 200
72+
73+ # Response headers passed to Dashboard via Nginx
74+ injectResponseHeaders:
75+ - name: Authorization
76+ values:
77+ - claim: id_token
78+ prefix: "Bearer "
79+ - name: X-Auth-Request-User
80+ values:
81+ - claim: email
82+ - name: X-Auth-Request-Email
83+ values:
84+ - claim: email
85+ - name: X-Auth-Request-Groups
86+ values:
87+ - claim: groups
88+
89+ server:
90+ BindAddress: "0.0.0.0:4180"
91+
92+extraArgs:
93+ cookie-domain: ".your-domain.com"
94+ whitelist-domain: ".your-domain.com"
95+ email-domain: "*" # Or restrict to your organization
96+ skip-provider-button: true
97+ reverse-proxy: true
98+ pass-authorization-header: true
99+ set-xauthrequest: true
100+
101+sessionStorage:
102+ type: redis
103+
104+redis:
105+ enabled: true
106+ auth:
107+ enabled: true
108+
109+ingress:
110+ enabled: true
111+ className: nginx
112+ hosts:
113+ - OAuth2 Proxy.your-domain.com
114+ path: /oauth2
115+ pathType: Prefix
116+```
117+
118+### Kubernetes Dashboard Ingress
119+
120+**Critical**: The Ingress must include `Authorization` in the `auth-response-headers` annotation:
121+
122+```yaml
123+apiVersion: networking.k8s.io/v1
124+kind: Ingress
125+metadata:
126+ name: kubernetes-dashboard
127+ namespace: kubernetes-dashboard
128+ annotations:
129+ nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
130+ nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
131+
132+ # OAuth2 Proxy authentication
133+ nginx.ingress.kubernetes.io/auth-url: "https://OAuth2 Proxy.your-domain.com/oauth2/auth"
134+ nginx.ingress.kubernetes.io/auth-signin: "https://OAuth2 Proxy.your-domain.com/oauth2/start?rd=$scheme://$best_http_host$request_uri"
135+
136+ # Include Authorization header with bearer token
137+ nginx.ingress.kubernetes.io/auth-response-headers: "Authorization, X-Auth-Request-User, X-Auth-Request-Email"
138+
139+ # Buffer sizes for large tokens (Entra tokens can exceed 4KB)
140+ nginx.ingress.kubernetes.io/proxy-buffer-size: "256k"
141+ nginx.ingress.kubernetes.io/proxy-buffers-number: "4"
142+ nginx.ingress.kubernetes.io/proxy-busy-buffers-size: "256k"
143+spec:
144+ ingressClassName: nginx
145+ tls:
146+ - hosts:
147+ - dashboard.your-domain.com
148+ secretName: dashboard-tls
149+ rules:
150+ - host: dashboard.your-domain.com
151+ http:
152+ paths:
153+ - path: /
154+ pathType: Prefix
155+ backend:
156+ service:
157+ name: kubernetes-dashboard-kong-proxy
158+ port:
159+ number: 443
160+```
161+
162+### RBAC Configuration
163+
164+Assign Kubernetes permissions to Entra ID users or groups.
165+
166+**User-based:**
167+```yaml
168+apiVersion: rbac.authorization.k8s.io/v1
169+kind: ClusterRoleBinding
170+metadata:
171+ name: dashboard-user-admin
172+roleRef:
173+ apiGroup: rbac.authorization.k8s.io
174+ kind: ClusterRole
175+ name: cluster-admin
176+subjects:
177+ - kind: User
178+ name: "user@your-domain.com" # Email from Entra ID token
179+ apiGroup: rbac.authorization.k8s.io
180+```
181+
182+**Group-based (recommended):**
183+```yaml
184+apiVersion: rbac.authorization.k8s.io/v1
185+kind: ClusterRoleBinding
186+metadata:
187+ name: dashboard-admins-group
188+roleRef:
189+ apiGroup: rbac.authorization.k8s.io
190+ kind: ClusterRole
191+ name: cluster-admin
192+subjects:
193+ - kind: Group
194+ name: "YOUR_ENTRA_GROUP_OBJECT_ID" # Entra ID Group Object ID
195+ apiGroup: rbac.authorization.k8s.io
196+```
197+
198+For production, create custom roles with limited permissions instead of using `cluster-admin`.
199+
200+### Troubleshooting
201+
202+**Dashboard still asks for token after authentication**
203+
204+Verify that:
205+1. `injectResponseHeaders` in alphaConfig includes Authorization header with id_token claim
206+2. Dashboard Ingress includes `Authorization` in `auth-response-headers` annotation
207+3. Buffer sizes are sufficient for large tokens (set to 256k as shown above)
208+4. Check OAuth2 Proxy logs for successful token generation: `kubectl logs -n OAuth2 Proxy <pod-name>`
209+
210+**"Unauthorized" or "Invalid token" errors**
211+
212+Common causes:
213+1. User/group not configured in Kubernetes RBAC
214+ - Check: `kubectl get clusterrolebindings | grep <user-email>`
215+2. Token validation failed
216+ - Verify AKS Entra ID integration is enabled
217+ - Check Dashboard logs: `kubectl logs -n kubernetes-dashboard <pod-name>`
218+3. Incorrect OAuth2 Proxy configuration
219+ - Ensure `reverse-proxy: true` is set
220+ - Verify issuer URL matches your tenant
221+
222+**Groups not included in token**
223+
224+To include groups in the token:
225+1. In Entra ID App Registration, go to **Token configuration**
226+2. Add **groups claim** and select security groups
227+3. Or edit the manifest and add: `"groupMembershipClaims": "SecurityGroup"`
228+4. For 200+ groups, ensure scope includes `User.Read` for group overage handling
229+5. Verify groups appear in token: check OAuth2 Proxy logs
230+
231+**Session expires too quickly**
232+
233+Configure cookie expiration:
234+```yaml
235+extraArgs:
236+ cookie-expire: "24h"
237+ cookie-refresh: "1h"
238+```
239+
240+### Using Workload Identity (Passwordless)
241+
242+For production environments, use Workload Identity instead of client secrets:
243+
244+```yaml
245+config:
246+ clientID: "YOUR_CLIENT_ID"
247+ secretKeys: # Exclude client-secret
248+ - client-id
249+ - cookie-secret
250+ cookieSecret: "YOUR_COOKIE_SECRET"
251+
252+serviceAccount:
253+ annotations:
254+ azure.workload.identity/client-id: YOUR_CLIENT_ID
255+ azure.workload.identity/tenant-id: YOUR_TENANT_ID
256+
257+podLabels:
258+ azure.workload.identity/use: "true"
259+
260+alphaConfig:
261+ enabled: true
262+ configData:
263+ providers:
264+ - id: azure-entra
265+ provider: entra-id
266+ clientID: YOUR_CLIENT_ID
267+ oidcConfig:
268+ issuerURL: https://login.microsoftonline.com/YOUR_TENANT_ID/v2.0
269+ # ... other config
270+ entraIdConfig:
271+ federatedTokenAuth: true
272+```
273+
274+This requires:
275+- AKS with OIDC issuer and Workload Identity enabled
276+- Federated identity credential configured in Entra ID App Registration
277+- Service account annotated with `azure.workload.identity/client-id`
278+
279+For detailed Workload Identity setup instructions, see the [Workload Identity section](../providers/ms_entra_id.md#workload-identity) in the Microsoft Entra ID provider documentation.
280+
281+## Integration with Other Providers
282+
283+While this guide focuses on Azure Entra ID, Kubernetes Dashboard can be integrated with other OAuth2 providers supported by OAuth2 Proxy. The key requirements remain the same:
284+
285+1. **Authorization Header**: Pass the bearer token via the `Authorization` header
286+2. **RBAC Configuration**: Configure Kubernetes RBAC for your authentication provider's users/groups
287+3. **Buffer Sizes**: Ensure adequate buffer sizes for tokens (especially important for OIDC providers)
288+
289+For provider-specific configuration examples, see the [OAuth Provider Configuration](../providers/index.md) documentation.
docs/docs/configuration/integrations/nginx.mdnew file+190
@@ -0,0 +1,190 @@
1+---
2+id: nginx
3+title: Nginx
4+---
5+
6+Configure OAuth2 Proxy with Nginx using the `auth_request` directive. Includes examples for both standalone Nginx configurations and Kubernetes ingress-nginx with annotations.
7+
8+**Key features:**
9+- Support for `auth_request` directive
10+- Kubernetes Ingress annotations
11+- Multi-part cookie handling for large tokens
12+- Session refresh support
13+
14+## Configuring for use with the Nginx `auth_request` directive
15+
16+**This option requires `--reverse-proxy` option to be set.**
17+
18+The [Nginx `auth_request` directive](http://nginx.org/en/docs/http/ngx_http_auth_request_module.html) allows Nginx to authenticate requests via the oauth2-proxy's `/auth` endpoint, which only returns a 202 Accepted response or a 401 Unauthorized response without proxying the request through. For example:
19+
20+```nginx
21+server {
22+ listen 443 ssl;
23+ server_name ...;
24+ include ssl/ssl.conf;
25+
26+ location /oauth2/ {
27+ proxy_pass http://127.0.0.1:4180;
28+ proxy_set_header Host $host;
29+ proxy_set_header X-Real-IP $remote_addr;
30+ proxy_set_header X-Auth-Request-Redirect $request_uri;
31+ # or, if you are handling multiple domains:
32+ # proxy_set_header X-Auth-Request-Redirect $scheme://$host$request_uri;
33+ }
34+ location = /oauth2/auth {
35+ proxy_pass http://127.0.0.1:4180;
36+ proxy_set_header Host $host;
37+ proxy_set_header X-Real-IP $remote_addr;
38+ proxy_set_header X-Forwarded-Uri $request_uri;
39+ # nginx auth_request includes headers but not body
40+ proxy_set_header Content-Length "";
41+ proxy_pass_request_body off;
42+ }
43+
44+ location / {
45+ auth_request /oauth2/auth;
46+ error_page 401 = @oauth2_signin;
47+
48+ # pass information via X-User and X-Email headers to backend,
49+ # requires running with --set-xauthrequest flag
50+ auth_request_set $user $upstream_http_x_auth_request_user;
51+ auth_request_set $email $upstream_http_x_auth_request_email;
52+ proxy_set_header X-User $user;
53+ proxy_set_header X-Email $email;
54+
55+ # if you enabled --pass-access-token, this will pass the token to the backend
56+ auth_request_set $token $upstream_http_x_auth_request_access_token;
57+ proxy_set_header X-Access-Token $token;
58+
59+ # if you enabled --cookie-refresh, this is needed for it to work with auth_request
60+ auth_request_set $auth_cookie $upstream_http_set_cookie;
61+ add_header Set-Cookie $auth_cookie;
62+
63+ # Large OIDC tokens can make the session cookie exceed the 4KB limit,
64+ # causing OAuth2 Proxy to split the cookie into multiple parts.
65+ # Nginx normally only copies the first `Set-Cookie` header from the auth_request to the response,
66+ # so extract the second part when using the default cookie name, `_oauth2_proxy`.
67+ auth_request_set $auth_cookie_upstream_1 $upstream_cookie__oauth2_proxy_1;
68+
69+ # Extract the Cookie attributes from the first Set-Cookie header and append them
70+ # to the second part ($upstream_cookie_* variables only contain the raw cookie content)
71+ if ($auth_cookie ~* "(; .*)") {
72+ set $auth_cookie_0 $auth_cookie;
73+ set $auth_cookie_1 "_oauth2_proxy_1=$auth_cookie_upstream_1$1";
74+ }
75+
76+ # Send both Set-Cookie headers now if there was a second part
77+ if ($auth_cookie_upstream_1) {
78+ add_header Set-Cookie $auth_cookie_0;
79+ add_header Set-Cookie $auth_cookie_1;
80+ }
81+
82+ proxy_pass http://backend/;
83+ # or "root /path/to/site;" or "fastcgi_pass ..." etc
84+ }
85+
86+ # Named location for handling OAuth2 sign-in redirects
87+ # This ensures the browser receives a proper 302 redirect that it will follow
88+ location @oauth2_signin {
89+ return 302 /oauth2/sign_in?rd=$scheme://$host$request_uri;
90+ }
91+}
92+```
93+
94+### Multi-part session cookies
95+
96+The example above is ready to use with the default `--cookie-name=_oauth2_proxy` setting and handles a session split into two cookies. If you configure a custom cookie name, update both references to the second cookie part:
97+
98+| Cookie configuration | Nginx upstream cookie variable | `Set-Cookie` name |
99+| --- | --- | --- |
100+| Default (`_oauth2_proxy`) | `$upstream_cookie__oauth2_proxy_1` | `_oauth2_proxy_1=` |
101+| `--cookie-name=my_cookie` | `$upstream_cookie_my_cookie_1` | `my_cookie_1=` |
102+
103+For example, with `--cookie-name=my_cookie`, change the relevant lines to:
104+
105+```nginx
106+auth_request_set $auth_cookie_upstream_1 $upstream_cookie_my_cookie_1;
107+set $auth_cookie_1 "my_cookie_1=$auth_cookie_upstream_1$1";
108+```
109+
110+If a session is split into more than two cookies, repeat the extraction for each additional numeric suffix. For consistently large sessions, prefer `--session-store-type=redis` so only a small session ticket is stored in the browser cookie.
111+
112+### Understanding the `error_page` redirect pattern
113+
114+The `auth_request` directive expects the authentication endpoint (`/oauth2/auth`) to return:
115+- **2xx**: Request is authenticated, allow access
116+- **401 or 403**: Request is not authenticated, deny access
117+
118+When a 401 is returned, nginx triggers the `error_page` directive. The recommended pattern uses a **named location** (`@oauth2_signin`) that returns a proper **302 redirect**:
119+
120+```nginx
121+error_page 401 = @oauth2_signin;
122+
123+location @oauth2_signin {
124+ return 302 /oauth2/sign_in?rd=$scheme://$host$request_uri;
125+}
126+```
127+
128+:::warning Avoid `error_page 401 =403` with sign_in
129+Some older configurations use `error_page 401 =403 /oauth2/sign_in`. While this works for displaying the sign-in page, it returns a **403 status code** with a `Location` header. Browsers do not automatically follow redirects on 403 responses, which can cause issues when using `--skip-provider-button=true` (users see a "Found." link instead of being automatically redirected).
130+
131+The named location pattern above ensures the browser receives a standard **302 redirect** that works correctly with all oauth2-proxy configurations.
132+:::
133+
134+### Browser vs API Routes
135+
136+:::important When to use redirects
137+Redirecting authentication failures (302 to `/oauth2/sign_in`) should **only be used for browser-facing routes**. API or machine clients should receive a plain 401/403 response without redirect.
138+:::
139+
140+#### Browser-facing routes (HTML, UI)
141+
142+For interactive browser routes where users should be redirected to sign in:
143+
144+```nginx
145+location / {
146+ auth_request /oauth2/auth;
147+ error_page 401 = @oauth2_signin;
148+ proxy_pass http://backend/;
149+}
150+
151+location @oauth2_signin {
152+ return 302 /oauth2/sign_in?rd=$scheme://$host$request_uri;
153+}
154+```
155+
156+#### API / Machine routes (no redirect)
157+
158+For API endpoints where clients expect a 401/403 status code (not a redirect):
159+
160+```nginx
161+location /api/ {
162+ auth_request /oauth2/auth;
163+ error_page 401 =401; # Pass through the 401 status
164+ proxy_pass http://backend/;
165+}
166+```
167+
168+This ensures:
169+- ✅ Browsers get a redirect and smooth login flow
170+- ✅ API clients fail fast with appropriate HTTP status codes
171+- ✅ `/oauth2/auth` remains a pure boolean oracle (2xx/401)
172+
173+When you use ingress-nginx in Kubernetes, you can configure the same behavior with the following annotations on your Ingress resource:
174+
175+```yaml
176+nginx.ingress.kubernetes.io/auth-url: "https://<oauth2-proxy-fqdn>/oauth2/auth"
177+nginx.ingress.kubernetes.io/auth-signin: "https://<oauth2-proxy-fqdn>/oauth2/start?rd=$escaped_request_uri"
178+```
179+
180+This minimal configuration works for standard authentication flows. Lua/cookie handling is only needed for advanced scenarios (e.g., multi-part cookies, custom session logic). See the official ingress-nginx example: https://kubernetes.github.io/ingress-nginx/examples/auth/oauth-external-auth/.
181+
182+It is recommended to use `--session-store-type=redis` when expecting large sessions/OIDC tokens (_e.g._ with MS Azure).
183+
184+:::tip Kubernetes Dashboard with Azure Entra ID
185+For a complete example of integrating oauth2-proxy with Kubernetes Dashboard on AKS using Azure Entra ID, including RBAC configuration and troubleshooting, see the [Kubernetes Dashboard on AKS](../providers/ms_entra_id.md#kubernetes-dashboard-on-aks) section in the Microsoft Entra ID provider documentation.
186+:::
187+
188+:::note
189+If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
190+:::
docs/docs/configuration/integrations/traefik.mdnew file+192
@@ -0,0 +1,192 @@
1+---
2+id: traefik
3+title: Traefik
4+---
5+
6+Set up OAuth2 Proxy with Traefik v2 using the `ForwardAuth` middleware. Includes examples for both error-based redirects and static upstream configurations.
7+
8+**Key features:**
9+- ForwardAuth middleware integration
10+- Error middleware for 401 redirects
11+- Static upstream configuration (202 responses)
12+- Dynamic file configuration examples
13+
14+
15+## Configuring for use with the Traefik (v2) `ForwardAuth` middleware
16+
17+**This option requires `--reverse-proxy` option to be set.**
18+
19+### ForwardAuth with 401 errors middleware
20+
21+The [Traefik v2 `ForwardAuth` middleware](https://doc.traefik.io/traefik/middlewares/http/forwardauth/) allows Traefik to authenticate requests via the oauth2-proxy's `/oauth2/auth` endpoint on every request, which only returns a 202 Accepted response or a 401 Unauthorized response without proxying the whole request through. For example, on Dynamic File (YAML) Configuration:
22+
23+```yaml
24+http:
25+ routers:
26+ a-service:
27+ rule: "Host(`a-service.example.com`)"
28+ service: a-service-backend
29+ middlewares:
30+ - oauth-errors
31+ - oauth-auth
32+ tls:
33+ certResolver: default
34+ domains:
35+ - main: "example.com"
36+ sans:
37+ - "*.example.com"
38+ oauth:
39+ rule: "Host(`a-service.example.com`, `oauth.example.com`) && PathPrefix(`/oauth2/`)"
40+ middlewares:
41+ - auth-headers
42+ service: oauth-backend
43+ tls:
44+ certResolver: default
45+ domains:
46+ - main: "example.com"
47+ sans:
48+ - "*.example.com"
49+
50+ services:
51+ a-service-backend:
52+ loadBalancer:
53+ servers:
54+ - url: http://172.16.0.2:7555
55+ oauth-backend:
56+ loadBalancer:
57+ servers:
58+ - url: http://172.16.0.1:4180
59+
60+ middlewares:
61+ auth-headers:
62+ headers:
63+ sslRedirect: true
64+ stsSeconds: 315360000
65+ browserXssFilter: true
66+ contentTypeNosniff: true
67+ forceSTSHeader: true
68+ sslHost: example.com
69+ stsIncludeSubdomains: true
70+ stsPreload: true
71+ frameDeny: true
72+ oauth-auth:
73+ forwardAuth:
74+ address: https://oauth.example.com/oauth2/auth
75+ trustForwardHeader: true
76+ oauth-errors:
77+ errors:
78+ status:
79+ - "401-403"
80+ service: oauth-backend
81+ query: "/oauth2/sign_in?rd={url}"
82+ statusRewrites:
83+ "401": 302
84+```
85+
86+:::caution Troubleshooting: Browser shows "Found." instead of redirecting
87+When using the Errors middleware without `statusRewrites`, the redirect response from oauth2-proxy can be served within the original 401/403 status context. This causes some browsers to display a "Found." link instead of automatically following the redirect to the identity provider.
88+
89+Adding `statusRewrites` to rewrite `401 -> 302` ensures the browser treats the response as a proper redirect and follows it automatically.
90+:::
91+
92+### ForwardAuth with static upstreams configuration
93+
94+Redirect to sign_in functionality provided without the use of `errors` middleware with [Traefik v2 `ForwardAuth` middleware](https://doc.traefik.io/traefik/middlewares/http/forwardauth/) pointing to oauth2-proxy service's `/` endpoint
95+
96+**Following options need to be set on `oauth2-proxy`:**
97+- `--upstream=static://202`: Configures a static response for authenticated sessions
98+- `--reverse-proxy=true`: Enables the use of `X-Forwarded-*` headers to determine redirects correctly
99+
100+```yaml
101+http:
102+ routers:
103+ a-service-route-1:
104+ rule: "Host(`a-service.example.com`, `b-service.example.com`) && PathPrefix(`/`)"
105+ service: a-service-backend
106+ middlewares:
107+ - oauth-auth-redirect # redirects all unauthenticated to oauth2 signin
108+ tls:
109+ certResolver: default
110+ domains:
111+ - main: "example.com"
112+ sans:
113+ - "*.example.com"
114+ a-service-route-2:
115+ rule: "Host(`a-service.example.com`) && PathPrefix(`/no-auto-redirect`)"
116+ service: a-service-backend
117+ middlewares:
118+ - oauth-auth-wo-redirect # unauthenticated session will return a 401
119+ tls:
120+ certResolver: default
121+ domains:
122+ - main: "example.com"
123+ sans:
124+ - "*.example.com"
125+ services-oauth2-route:
126+ rule: "Host(`a-service.example.com`, `b-service.example.com`) && PathPrefix(`/oauth2/`)"
127+ middlewares:
128+ - auth-headers
129+ service: oauth-backend
130+ tls:
131+ certResolver: default
132+ domains:
133+ - main: "example.com"
134+ sans:
135+ - "*.example.com"
136+ oauth2-proxy-route:
137+ rule: "Host(`oauth.example.com`) && PathPrefix(`/`)"
138+ middlewares:
139+ - auth-headers
140+ service: oauth-backend
141+ tls:
142+ certResolver: default
143+ domains:
144+ - main: "example.com"
145+ sans:
146+ - "*.example.com"
147+
148+ services:
149+ a-service-backend:
150+ loadBalancer:
151+ servers:
152+ - url: http://172.16.0.2:7555
153+ b-service-backend:
154+ loadBalancer:
155+ servers:
156+ - url: http://172.16.0.3:7555
157+ oauth-backend:
158+ loadBalancer:
159+ servers:
160+ - url: http://172.16.0.1:4180
161+
162+ middlewares:
163+ auth-headers:
164+ headers:
165+ sslRedirect: true
166+ stsSeconds: 315360000
167+ browserXssFilter: true
168+ contentTypeNosniff: true
169+ forceSTSHeader: true
170+ sslHost: example.com
171+ stsIncludeSubdomains: true
172+ stsPreload: true
173+ frameDeny: true
174+ oauth-auth-redirect:
175+ forwardAuth:
176+ address: https://oauth.example.com/
177+ trustForwardHeader: true
178+ authResponseHeaders:
179+ - X-Auth-Request-Access-Token
180+ - Authorization
181+ oauth-auth-wo-redirect:
182+ forwardAuth:
183+ address: https://oauth.example.com/oauth2/auth
184+ trustForwardHeader: true
185+ authResponseHeaders:
186+ - X-Auth-Request-Access-Token
187+ - Authorization
188+```
189+
190+:::note
191+If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
192+:::
docs/docs/configuration/overview.md+330−487
@@ -5,7 +5,7 @@ title: Overview
55
66`oauth2-proxy` can be configured via [command line options](#command-line-options), [environment variables](#environment-variables) or [config file](#config-file) (in decreasing order of precedence, i.e. command line options will overwrite environment variables and environment variables will overwrite configuration file settings).
77
8−### Generating a Cookie Secret
8+## Generating a Cookie Secret
99
1010To generate a strong cookie secret use one of the below commands:
1111
@@ -15,220 +15,319 @@ import TabItem from '@theme/TabItem';
1515<Tabs defaultValue="python">
1616 <TabItem value="python" label="Python">
1717
18− ```shell
19− python -c 'import os,base64; print(base64.urlsafe_b64encode(os.urandom(32)).decode())'
20− ```
21−
18+```shell
19+python -c 'import os,base64; print(base64.urlsafe_b64encode(os.urandom(32)).decode())'
20+```
21+
2222 </TabItem>
2323 <TabItem value="bash" label="Bash">
2424
25− ```shell
26− dd if=/dev/urandom bs=32 count=1 2>/dev/null | base64 | tr -d -- '\n' | tr -- '+/' '-_' ; echo
27− ```
28−
25+```shell
26+dd if=/dev/urandom bs=32 count=1 2>/dev/null | base64 | tr -d -- '\n' | tr -- '+/' '-_' ; echo
27+```
28+
2929 </TabItem>
3030 <TabItem value="openssl" label="OpenSSL">
3131
32− ```shell
33− openssl rand -base64 32 | tr -- '+/' '-_'
34− ```
32+```shell
33+openssl rand -base64 32 | tr -- '+/' '-_'
34+```
3535
3636 </TabItem>
3737 <TabItem value="powershell" label="PowerShell">
3838
39− ```powershell
40− # Add System.Web assembly to session, just in case
41− Add-Type -AssemblyName System.Web
42− [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes([System.Web.Security.Membership]::GeneratePassword(32,4))).Replace("+","-").Replace("/","_")
43− ```
39+```powershell
40+# Add System.Web assembly to session, just in case
41+Add-Type -AssemblyName System.Web
42+[Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes([System.Web.Security.Membership]::GeneratePassword(32,4))).Replace("+","-").Replace("/","_")
43+```
4444
4545 </TabItem>
4646 <TabItem value="terraform" label="Terraform">
4747
48− ```hcl
49− # Valid 32 Byte Base64 URL encoding set that will decode to 24 []byte AES-192 secret
50− resource "random_password" "cookie_secret" {
51− length = 32
52− override_special = "-_"
53− }
54− ```
48+```hcl
49+# Valid 32 Byte Base64 URL encoding set that will decode to 24 []byte AES-192 secret
50+resource "random_password" "cookie_secret" {
51+ length = 32
52+ override_special = "-_"
53+}
54+```
5555
5656 </TabItem>
5757</Tabs>
5858
59−### Config File
59+## Config File
6060
6161Every command line argument can be specified in a config file by replacing hyphens (-) with underscores (\_). If the argument can be specified multiple times, the config option should be plural (trailing s).
6262
6363An example [oauth2-proxy.cfg](https://github.com/oauth2-proxy/oauth2-proxy/blob/master/contrib/oauth2-proxy.cfg.example) config file is in the contrib directory. It can be used by specifying `--config=/etc/oauth2-proxy.cfg`
6464
65+## Config Options
66+
6567### Command Line Options
6668
67−| Option | Type | Description | Default |
68−| ------ | ---- | ----------- | ------- |
69−| `--acr-values` | string | optional, see [docs](https://openid.net/specs/openid-connect-eap-acr-values-1_0.html#acrValues) | `""` |
70−| `--allow-query-semicolons` | bool | allow the use of semicolons in query args ([required for some legacy applications](https://github.com/golang/go/issues/25192)) | `false` |
71−| `--api-route` | string \| list | return HTTP 401 instead of redirecting to authentication server if token is not valid. Format: path_regex | |
72−| `--approval-prompt` | string | OAuth approval_prompt | `"force"` |
73−| `--auth-logging` | bool | Log authentication attempts | true |
74−| `--auth-logging-format` | string | Template for authentication log lines | see [Logging Configuration](#logging-configuration) |
75−| `--authenticated-emails-file` | string | authenticate against emails via file (one per line) | |
76−| `--azure-tenant` | string | go to a tenant-specific or common (tenant-independent) endpoint. | `"common"` |
77−| `--backend-logout-url` | string | URL to perform backend logout, if you use `{id_token}` in the url it will be replaced by the actual `id_token` of the user session | |
78−| `--basic-auth-password` | string | the password to set when passing the HTTP Basic Auth header | |
79−| `--client-id` | string | the OAuth Client ID, e.g. `"123456.apps.googleusercontent.com"` | |
80−| `--client-secret` | string | the OAuth Client Secret | |
81−| `--client-secret-file` | string | the file with OAuth Client Secret | |
82−| `--code-challenge-method` | string | use PKCE code challenges with the specified method. Either 'plain' or 'S256' (recommended) | |
83−| `--config` | string | path to config file | |
84−| `--cookie-domain` | string \| list | Optional cookie domains to force cookies to (e.g. `.yourcompany.com`). The longest domain matching the request's host will be used (or the shortest cookie domain if there is no match). | |
85−| `--cookie-expire` | duration | expire timeframe for cookie. If set to 0, cookie becomes a session-cookie which will expire when the browser is closed. | 168h0m0s |
86−| `--cookie-httponly` | bool | set HttpOnly cookie flag | true |
87−| `--cookie-name` | string | the name of the cookie that the oauth_proxy creates. Should be changed to use a [cookie prefix](https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#cookie_prefixes) (`__Host-` or `__Secure-`) if `--cookie-secure` is set. | `"_oauth2_proxy"` |
88−| `--cookie-path` | string | an optional cookie path to force cookies to (e.g. `/poc/`) | `"/"` |
89−| `--cookie-refresh` | duration | refresh the cookie after this duration; `0` to disable; not supported by all providers&nbsp;[^1] | |
90−| `--cookie-secret` | string | the seed string for secure cookies (optionally base64 encoded) | |
91−| `--cookie-secure` | bool | set [secure (HTTPS only) cookie flag](https://owasp.org/www-community/controls/SecureFlag) | true |
92−| `--cookie-samesite` | string | set SameSite cookie attribute (`"lax"`, `"strict"`, `"none"`, or `""`). | `""` |
93−| `--cookie-csrf-per-request` | bool | Enable having different CSRF cookies per request, making it possible to have parallel requests. | false |
94−| `--cookie-csrf-expire` | duration | expire timeframe for CSRF cookie | 15m |
95−| `--custom-templates-dir` | string | path to custom html templates | |
96−| `--custom-sign-in-logo` | string | path or a URL to an custom image for the sign_in page logo. Use `"-"` to disable default logo. |
97−| `--display-htpasswd-form` | bool | display username / password login form if an htpasswd file is provided | true |
98−| `--email-domain` | string \| list | authenticate emails with the specified domain (may be given multiple times). Use `*` to authenticate any email | |
99−| `--errors-to-info-log` | bool | redirects error-level logging to default log channel instead of stderr | false |
100−| `--extra-jwt-issuers` | string | if `--skip-jwt-bearer-tokens` is set, a list of extra JWT `issuer=audience` (see a token's `iss`, `aud` fields) pairs (where the issuer URL has a `.well-known/openid-configuration` or a `.well-known/jwks.json`) | |
101−| `--exclude-logging-path` | string | comma separated list of paths to exclude from logging, e.g. `"/ping,/path2"` |`""` (no paths excluded) |
102−| `--flush-interval` | duration | period between flushing response buffers when streaming responses | `"1s"` |
103−| `--force-https` | bool | enforce https redirect | `false` |
104−| `--force-json-errors` | bool | force JSON errors instead of HTTP error pages or redirects | `false` |
105−| `--banner` | string | custom (html) banner string. Use `"-"` to disable default banner. | |
106−| `--footer` | string | custom (html) footer string. Use `"-"` to disable default footer. | |
107−| `--github-org` | string | restrict logins to members of this organisation | |
108−| `--github-team` | string | restrict logins to members of any of these teams (slug), separated by a comma | |
109−| `--github-repo` | string | restrict logins to collaborators of this repository formatted as `orgname/repo` | |
110−| `--github-token` | string | the token to use when verifying repository collaborators (must have push access to the repository) | |
111−| `--github-user` | string \| list | To allow users to login by username even if they do not belong to the specified org and team or collaborators | |
112−| `--gitlab-group` | string \| list | restrict logins to members of any of these groups (slug), separated by a comma | |
113−| `--gitlab-projects` | string \| list | restrict logins to members of any of these projects (may be given multiple times) formatted as `orgname/repo=accesslevel`. Access level should be a value matching [Gitlab access levels](https://docs.gitlab.com/ee/api/members.html#valid-access-levels), defaulted to 20 if absent | |
114−| `--google-admin-email` | string | the google admin to impersonate for api calls | |
115−| `--google-group` | string | restrict logins to members of this google group (may be given multiple times). | |
116−| `--google-service-account-json` | string | the path to the service account json credentials | |
117−| `--google-use-application-default-credentials` | bool | use application default credentials instead of service account json (i.e. GKE Workload Identity) | |
118−| `--google-target-principal` | bool | the target principal to impersonate when using ADC | defaults to the service account configured for ADC |
119−| `--htpasswd-file` | string | additionally authenticate against a htpasswd file. Entries must be created with `htpasswd -B` for bcrypt encryption | |
120−| `--htpasswd-user-group` | string \| list | the groups to be set on sessions for htpasswd users | |
121−| `--http-address` | string | `[http://]<addr>:<port>` or `unix://<path>` to listen on for HTTP clients. Square brackets are required for ipv6 address, e.g. `http://[::1]:4180` | `"127.0.0.1:4180"` |
122−| `--https-address` | string | `[https://]<addr>:<port>` to listen on for HTTPS clients. Square brackets are required for ipv6 address, e.g. `https://[::1]:443` | `":443"` |
123−| `--logging-compress` | bool | Should rotated log files be compressed using gzip | false |
124−| `--logging-filename` | string | File to log requests to, empty for `stdout` | `""` (stdout) |
125−| `--logging-local-time` | bool | Use local time in log files and backup filenames instead of UTC | true (local time) |
126−| `--logging-max-age` | int | Maximum number of days to retain old log files | 7 |
127−| `--logging-max-backups` | int | Maximum number of old log files to retain; 0 to disable | 0 |
128−| `--logging-max-size` | int | Maximum size in megabytes of the log file before rotation | 100 |
129−| `--jwt-key` | string | private key in PEM format used to sign JWT, so that you can say something like `--jwt-key="${OAUTH2_PROXY_JWT_KEY}"`: required by login.gov | |
130−| `--jwt-key-file` | string | path to the private key file in PEM format used to sign the JWT so that you can say something like `--jwt-key-file=/etc/ssl/private/jwt_signing_key.pem`: required by login.gov | |
131−| `--login-url` | string | Authentication endpoint | |
132−| `--insecure-oidc-allow-unverified-email` | bool | don't fail if an email address in an id_token is not verified | false |
133−| `--insecure-oidc-skip-issuer-verification` | bool | allow the OIDC issuer URL to differ from the expected (currently required for Azure multi-tenant compatibility) | false |
134−| `--insecure-oidc-skip-nonce` | bool | skip verifying the OIDC ID Token's nonce claim | true |
135−| `--oidc-issuer-url` | string | the OpenID Connect issuer URL, e.g. `"https://accounts.google.com"` | |
136−| `--oidc-jwks-url` | string | OIDC JWKS URI for token verification; required if OIDC discovery is disabled | |
137−| `--oidc-email-claim` | string | which OIDC claim contains the user's email | `"email"` |
138−| `--oidc-groups-claim` | string | which OIDC claim contains the user groups | `"groups"` |
139−| `--oidc-audience-claim` | string | which OIDC claim contains the audience | `"aud"` |
140−| `--oidc-extra-audience` | string \| list | additional audiences which are allowed to pass verification | `"[]"` |
141−| `--pass-access-token` | bool | pass OAuth access_token to upstream via X-Forwarded-Access-Token header. When used with `--set-xauthrequest` this adds the X-Auth-Request-Access-Token header to the response | false |
142−| `--pass-authorization-header` | bool | pass OIDC IDToken to upstream via Authorization Bearer header | false |
143−| `--pass-basic-auth` | bool | pass HTTP Basic Auth, X-Forwarded-User, X-Forwarded-Email and X-Forwarded-Preferred-Username information to upstream | true |
144−| `--prefer-email-to-user` | bool | Prefer to use the Email address as the Username when passing information to upstream. Will only use Username if Email is unavailable, e.g. htaccess authentication. Used in conjunction with `--pass-basic-auth` and `--pass-user-headers` | false |
145−| `--pass-host-header` | bool | pass the request Host Header to upstream | true |
146−| `--pass-user-headers` | bool | pass X-Forwarded-User, X-Forwarded-Groups, X-Forwarded-Email and X-Forwarded-Preferred-Username information to upstream | true |
147−| `--profile-url` | string | Profile access endpoint | |
148−| `--skip-claims-from-profile-url` | bool | skip request to Profile URL for resolving claims not present in id_token | false |
149−| `--prompt` | string | [OIDC prompt](https://openid.net/specs/openid-connect-core-1_0.html#AuthRequest); if present, `approval-prompt` is ignored | `""` |
150−| `--provider` | string | OAuth provider | google |
151−| `--provider-ca-file` | string \| list | Paths to CA certificates that should be used when connecting to the provider. If not specified, the default Go trust sources are used instead. |
152−| `--use-system-trust-store` | bool | Determines if `provider-ca-file` files and the system trust store are used. If set to true, your custom CA files and the system trust store are used otherwise only your custom CA files. | false |
153−| `--provider-display-name` | string | Override the provider's name with the given string; used for the sign-in page | (depends on provider) |
154−| `--ping-path` | string | the ping endpoint that can be used for basic health checks | `"/ping"` |
155−| `--ping-user-agent` | string | a User-Agent that can be used for basic health checks | `""` (don't check user agent) |
156−| `--ready-path` | string | the ready endpoint that can be used for deep health checks | `"/ready"` |
157−| `--metrics-address` | string | the address prometheus metrics will be scraped from | `""` |
158−| `--proxy-prefix` | string | the url root path that this proxy should be nested under (e.g. /`<oauth2>/sign_in`) | `"/oauth2"` |
159−| `--proxy-websockets` | bool | enables WebSocket proxying | true |
160−| `--pubjwk-url` | string | JWK pubkey access endpoint: required by login.gov | |
161−| `--real-client-ip-header` | string | Header used to determine the real IP of the client, requires `--reverse-proxy` to be set (one of: X-Forwarded-For, X-Real-IP, or X-ProxyUser-IP) | X-Real-IP |
162−| `--redeem-url` | string | Token redemption endpoint | |
163−| `--redirect-url` | string | the OAuth Redirect URL, e.g. `"https://internalapp.yourcompany.com/oauth2/callback"` | |
164−| `--relative-redirect-url` | bool | allow relative OAuth Redirect URL.` | false |
165−| `--redis-cluster-connection-urls` | string \| list | List of Redis cluster connection URLs (e.g. `redis://HOST[:PORT]`). Used in conjunction with `--redis-use-cluster` | |
166−| `--redis-connection-url` | string | URL of redis server for redis session storage (e.g. `redis://HOST[:PORT]`) | |
167−| `--redis-insecure-skip-tls-verify` | bool | skip TLS verification when connecting to Redis | false |
168−| `--redis-password` | string | Redis password. Applicable for all Redis configurations. Will override any password set in `--redis-connection-url` | |
169−| `--redis-sentinel-password` | string | Redis sentinel password. Used only for sentinel connection; any redis node passwords need to use `--redis-password` | |
170−| `--redis-sentinel-master-name` | string | Redis sentinel master name. Used in conjunction with `--redis-use-sentinel` | |
171−| `--redis-sentinel-connection-urls` | string \| list | List of Redis sentinel connection URLs (e.g. `redis://HOST[:PORT]`). Used in conjunction with `--redis-use-sentinel` | |
172−| `--redis-use-cluster` | bool | Connect to redis cluster. Must set `--redis-cluster-connection-urls` to use this feature | false |
173−| `--redis-use-sentinel` | bool | Connect to redis via sentinels. Must set `--redis-sentinel-master-name` and `--redis-sentinel-connection-urls` to use this feature | false |
174−| `--redis-connection-idle-timeout` | int | Redis connection idle timeout seconds. If Redis [timeout](https://redis.io/docs/reference/clients/#client-timeouts) option is set to non-zero, the `--redis-connection-idle-timeout` must be less than Redis timeout option. Example: if either redis.conf includes `timeout 15` or using `CONFIG SET timeout 15` the `--redis-connection-idle-timeout` must be at least `--redis-connection-idle-timeout=14` | 0 |
175−| `--request-id-header` | string | Request header to use as the request ID in logging | X-Request-Id |
176−| `--request-logging` | bool | Log requests | true |
177−| `--request-logging-format` | string | Template for request log lines | see [Logging Configuration](#logging-configuration) |
178−| `--resource` | string | The resource that is protected (Azure AD only) | |
179−| `--reverse-proxy` | bool | are we running behind a reverse proxy, controls whether headers like X-Real-IP are accepted and allows X-Forwarded-\{Proto,Host,Uri\} headers to be used on redirect selection | false |
180−| `--scope` | string | OAuth scope specification | |
181−| `--session-cookie-minimal` | bool | strip OAuth tokens from cookie session stores if they aren't needed (cookie session store only) | false |
182−| `--session-store-type` | string | [Session data storage backend](sessions.md); redis or cookie | cookie |
183−| `--set-xauthrequest` | bool | set X-Auth-Request-User, X-Auth-Request-Groups, X-Auth-Request-Email and X-Auth-Request-Preferred-Username response headers (useful in Nginx auth_request mode). When used with `--pass-access-token`, X-Auth-Request-Access-Token is added to response headers. | false |
184−| `--set-authorization-header` | bool | set Authorization Bearer response header (useful in Nginx auth_request mode) | false |
185−| `--set-basic-auth` | bool | set HTTP Basic Auth information in response (useful in Nginx auth_request mode) | false |
186−| `--show-debug-on-error` | bool | show detailed error information on error pages (WARNING: this may contain sensitive information - do not use in production) | false |
187−| `--signature-key` | string | GAP-Signature request signature key (algorithm:secretkey) | |
188−| `--silence-ping-logging` | bool | disable logging of requests to ping & ready endpoints | false |
189−| `--skip-auth-preflight` | bool | will skip authentication for OPTIONS requests | false |
190−| `--skip-auth-regex` | string \| list | (DEPRECATED for `--skip-auth-route`) bypass authentication for requests paths that match (may be given multiple times) | |
191−| `--skip-auth-route` | string \| list | bypass authentication for requests that match the method & path. Format: method=path_regex OR method!=path_regex. For all methods: path_regex OR !=path_regex | |
192−| `--skip-auth-strip-headers` | bool | strips `X-Forwarded-*` style authentication headers & `Authorization` header if they would be set by oauth2-proxy | true |
193−| `--skip-jwt-bearer-tokens` | bool | will skip requests that have verified JWT bearer tokens (the token must have [`aud`](https://en.wikipedia.org/wiki/JSON_Web_Token#Standard_fields) that matches this client id or one of the extras from `extra-jwt-issuers`) | false |
194−| `--skip-oidc-discovery` | bool | bypass OIDC endpoint discovery. `--login-url`, `--redeem-url` and `--oidc-jwks-url` must be configured in this case | false |
195−| `--skip-provider-button` | bool | will skip sign-in-page to directly reach the next step: oauth/start | false |
196−| `--ssl-insecure-skip-verify` | bool | skip validation of certificates presented when using HTTPS providers | false |
197−| `--ssl-upstream-insecure-skip-verify` | bool | skip validation of certificates presented when using HTTPS upstreams | false |
198−| `--standard-logging` | bool | Log standard runtime information | true |
199−| `--standard-logging-format` | string | Template for standard log lines | see [Logging Configuration](#logging-configuration) |
200−| `--tls-cert-file` | string | path to certificate file | |
201−| `--tls-cipher-suite` | string \| list | Restricts TLS cipher suites used by server to those listed (e.g. TLS_RSA_WITH_RC4_128_SHA) (may be given multiple times). If not specified, the default Go safe cipher list is used. List of valid cipher suites can be found in the [crypto/tls documentation](https://pkg.go.dev/crypto/tls#pkg-constants). | |
202−| `--tls-key-file` | string | path to private key file | |
203−| `--tls-min-version` | string | minimum TLS version that is acceptable, either `"TLS1.2"` or `"TLS1.3"` | `"TLS1.2"` |
204−| `--upstream` | string \| list | the http url(s) of the upstream endpoint, file:// paths for static files or `static://<status_code>` for static response. Routing is based on the path | |
205−| `--upstream-timeout` | duration | maximum amount of time the server will wait for a response from the upstream | 30s |
206−| `--allowed-group` | string \| list | restrict logins to members of this group (may be given multiple times) | |
207−| `--allowed-role` | string \| list | restrict logins to users with this role (may be given multiple times). Only works with the keycloak-oidc provider. | |
208−| `--validate-url` | string | Access token validation endpoint | |
209−| `--version` | n/a | print version string | |
210−| `--whitelist-domain` | string \| list | allowed domains for redirection after authentication. Prefix domain with a `.` or a `*.` to allow subdomains (e.g. `.example.com`, `*.example.com`)&nbsp;[^2] | |
211−| `--trusted-ip` | string \| list | list of IPs or CIDR ranges to allow to bypass authentication (may be given multiple times). When combined with `--reverse-proxy` and optionally `--real-client-ip-header` this will evaluate the trust of the IP stored in an HTTP header by a reverse proxy rather than the layer-3/4 remote address. WARNING: trusting IPs has inherent security flaws, especially when obtaining the IP address from an HTTP header (reverse-proxy mode). Use this option only if you understand the risks and how to manage them. | |
212−| `--encode-state` | bool | encode the state parameter as UrlEncodedBase64 | false |
213−
214−[^1]: Only these providers support `--cookie-refresh`: GitLab, Google and OIDC
215−[^2]: When using the `whitelist-domain` option, any domain prefixed with a `.` or a `*.` will allow any subdomain of the specified domain as a valid redirect URL. By default, only empty ports are allowed. This translates to allowing the default port of the URLs protocol (80 for HTTP, 443 for HTTPS, etc.) since browsers omit them. To allow only a specific port, add it to the whitelisted domain: `example.com:8080`. To allow any port, use `*`: `example.com:*`.
216−
217−See below for provider specific options
218−
219−### Upstreams Configuration
69+| Flag | Description |
70+| ---------------- | ------------------------------------------------------- |
71+| `--config` | path to config file |
72+| `--config-test` | test configuration and exit (for CI/CD validation) |
73+| `--version` | print version string |
74+
75+### General Provider Options
76+
77+Provider specific options can be found on their respective subpages.
78+
79+| Flag / Config Field | Type | Description | Default |
80+| --------------------------------------------------------------------------------------------------- | -------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------- |
81+| flag: `--acr-values`<br/>toml: `acr_values` | string | optional, see [docs](https://openid.net/specs/openid-connect-eap-acr-values-1_0.html#acrValues) | `""` |
82+| flag: `--allowed-group`<br/>toml: `allowed_groups` | string \| list | Restrict login to members of a group or list of groups. Furthermore, if you aren't setting the `scope` and use `allowed_groups` with the generic OIDC provider the scope `groups` gets added implicitly. | |
83+| flag: `--approval-prompt`<br/>toml: `approval_prompt` | string | OAuth approval_prompt | `"force"` |
84+| flag: `--backend-logout-url`<br/>toml: `backend_logout_url` | string | URL to perform backend logout, if you use `{id_token}` in the url it will be replaced by the actual `id_token` of the user session | |
85+| flag: `--client-id`<br/>toml: `client_id` | string | the OAuth Client ID, e.g. `"123456.apps.googleusercontent.com"` | |
86+| flag: `--client-secret-file`<br/>toml: `client_secret_file` | string | the file with OAuth Client Secret. The file must contain the secret only, with no trailing newline | |
87+| flag: `--client-secret`<br/>toml: `client_secret` | string | the OAuth Client Secret | |
88+| flag: `--code-challenge-method`<br/>toml: `code_challenge_method` | string | use PKCE code challenges with the specified method. Either 'plain' or 'S256' (recommended) | |
89+| flag: `--insecure-oidc-allow-unverified-email`<br/>toml: `insecure_oidc_allow_unverified_email` | bool | don't fail if an email address in an id_token is not verified | false |
90+| flag: `--insecure-oidc-skip-issuer-verification`<br/>toml: `insecure_oidc_skip_issuer_verification` | bool | allow the OIDC issuer URL to differ from the expected (currently required for Azure multi-tenant compatibility) | false |
91+| flag: `--insecure-oidc-skip-nonce`<br/>toml: `insecure_oidc_skip_nonce` | bool | skip verifying the OIDC ID Token's nonce claim | true |
92+| flag: `--jwt-key-file`<br/>toml: `jwt_key_file` | string | path to the private key file in PEM format used to sign the JWT so that you can say something like `--jwt-key-file=/etc/ssl/private/jwt_signing_key.pem`: required by login.gov | |
93+| flag: `--jwt-key`<br/>toml: `jwt_key` | string | private key in PEM format used to sign JWT, so that you can say something like `--jwt-key="${OAUTH2_PROXY_JWT_KEY}"`: required by login.gov | |
94+| flag: `--login-url`<br/>toml: `login_url` | string | Authentication endpoint | |
95+| flag: `--auth-request-response-mode`<br/>toml: `auth-request-response-mode` | string | Response mode to ask for during authentication request | |
96+| flag: `--oidc-audience-claim`<br/>toml: `oidc_audience_claims` | string | which OIDC claim contains the audience | `"aud"` |
97+| flag: `--oidc-email-claim`<br/>toml: `oidc_email_claim` | string | which OIDC claim contains the user's email | `"email"` |
98+| flag: `--oidc-extra-audience`<br/>toml: `oidc_extra_audiences` | string \| list | additional audiences which are allowed to pass verification | `"[]"` |
99+| flag: `--oidc-groups-claim`<br/>toml: `oidc_groups_claim` | string | which OIDC claim contains the user groups | `"groups"` |
100+| flag: `--oidc-issuer-url`<br/>toml: `oidc_issuer_url` | string | the OpenID Connect issuer URL, e.g. `"https://accounts.google.com"` | |
101+| flag: `--oidc-jwks-url`<br/>toml: `oidc_jwks_url` | string | OIDC JWKS URI for token verification; required if OIDC discovery is disabled and public key files are not provided | |
102+| flag: `--oidc-public-key-file`<br/>toml: `oidc_public_key_files` | string | Path to public key file in PEM format to use for verifying JWT tokens (may be given multiple times). Required if OIDC discovery is disabled na JWKS URL isn't provided | |
103+| flag: `--oidc-enabled-signing-alg`<br/>toml: `oidc_enabled_signing_algs` | string \| list | List of allowed JWT signing algorithms. When oidc discovery is enabled, the effective set is the intersection between this list and the provider's discovered supported algorithms. | |
104+| flag: `--profile-url`<br/>toml: `profile_url` | string | Profile access endpoint | |
105+| flag: `--prompt`<br/>toml: `prompt` | string | [OIDC prompt](https://openid.net/specs/openid-connect-core-1_0.html#AuthRequest); if present, `approval-prompt` is ignored | `""` |
106+| flag: `--provider-ca-file`<br/>toml: `provider_ca_files` | string \| list | Paths to CA certificates that should be used when connecting to the provider. If not specified, the default Go trust sources are used instead. | |
107+| flag: `--provider-display-name`<br/>toml: `provider_display_name` | string | Override the provider's name with the given string; used for the sign-in page | (depends on provider) |
108+| flag: `--provider`<br/>toml: `provider` | string | OAuth provider | google |
109+| flag: `--pubjwk-url`<br/>toml: `pubjwk_url` | string | JWK pubkey access endpoint: required by login.gov | |
110+| flag: `--redeem-url`<br/>toml: `redeem_url` | string | Token redemption endpoint | |
111+| flag: `--scope`<br/>toml:`scope` | string | OAuth scope specification. Every provider has a default list of scopes which will be used in case no scope is configured. | |
112+| flag: `--skip-claims-from-profile-url`<br/>toml: `skip_claims_from_profile_url` | bool | skip request to Profile URL for resolving claims not present in id_token | false |
113+| flag: `--skip-oidc-discovery`<br/>toml: `skip_oidc_discovery` | bool | bypass OIDC endpoint discovery. `--login-url`, `--redeem-url` and `--oidc-jwks-url` must be configured in this case | false |
114+| flag: `--use-system-trust-store`<br/>toml: `use_system_trust_store` | bool | Determines if `provider-ca-file` files and the system trust store are used. If set to true, your custom CA files and the system trust store are used otherwise only your custom CA files. | false |
115+| flag: `--validate-url`<br/>toml: `validate_url` | string | Access token validation endpoint | |
116+
117+### Cookie Options
118+
119+| Flag / Config Field | Type | Description | Default |
120+| --------------------------------------------------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------- |
121+| flag: `--cookie-csrf-expire`<br/>toml: `cookie_csrf_expire` | duration | expire timeframe for CSRF cookie | 15m |
122+| flag: `--cookie-csrf-per-request`<br/>toml:`cookie_csrf_per_request` | bool | Enable having different CSRF cookies per request, making it possible to have parallel requests. | false |
123+| flag: `--cookie-csrf-per-request-limit`<br/>toml: `cookie_csrf_per_request_limit` | int | Sets a limit on the number of CSRF requests cookies that oauth2-proxy will create. The oldest cookie will be removed. Useful if users end up with 431 Request headers too large status codes. Only effective if --cookie-csrf-per-request is true | "infinite" |
124+| flag: `--cookie-csrf-samesite`<br/>toml: `cookie_csrf_samesite` | string | set SameSite CSRF cookie attribute (`"lax"`, `"strict"`, `"none"`, or `""`). When using the default setting, the CSRF cookie samesite value is taken from the session cookie configuration. | `""` |
125+| flag: `--cookie-domain`<br/>toml: `cookie_domains` | string \| list | Optional cookie domains to force cookies to (e.g. `.yourcompany.com`). The longest domain matching the request's host will be used (or the shortest cookie domain if there is no match). | |
126+| flag: `--cookie-expire`<br/>toml: `cookie_expire` | duration | expire timeframe for cookie. If set to 0, cookie becomes a session-cookie which will expire when the browser is closed. | 168h0m0s |
127+| flag: `--cookie-httponly`<br/>toml: `cookie_httponly` | bool | set HttpOnly cookie flag | true |
128+| flag: `--cookie-name`<br/>toml: `cookie_name` | string | the name of the cookie that the oauth_proxy creates. Should be changed to use a [cookie prefix](https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#cookie_prefixes) (`__Host-` or `__Secure-`) if `--cookie-secure` is set. | `"_oauth2_proxy"` |
129+| flag: `--cookie-path`<br/>toml: `cookie_path` | string | an optional cookie path to force cookies to (e.g. `/poc/`) | `"/"` |
130+| flag: `--cookie-refresh`<br/>toml: `cookie_refresh` | duration | refresh the cookie after this duration; `0` to disable; not supported by all providers&nbsp;[^1] | |
131+| flag: `--cookie-samesite`<br/>toml: `cookie_samesite` | string | set SameSite cookie attribute (`"lax"`, `"strict"`, `"none"`, or `""`). | `""` |
132+| flag: `--cookie-secret`<br/>toml: `cookie_secret` | string | the seed string for secure cookies (optionally base64 encoded) | |
133+| flag: `--cookie-secret-file`<br/>toml: `cookie_secret_file` | string | File containing the cookie secret (must be raw binary, exactly 16, 24, or 32 bytes). Use dd if=/dev/urandom bs=32 count=1 > cookie.secret to generate | |
134+| flag: `--cookie-secure`<br/>toml: `cookie_secure` | bool | set [secure (HTTPS only) cookie flag](https://owasp.org/www-community/controls/SecureFlag) | true |
135+
136+[^1]: The following providers support `--cookie-refresh`: ADFS, Azure, GitLab, Google, Keycloak and all other Identity Providers which support the full [OIDC specification](https://openid.net/specs/openid-connect-core-1_0.html#RefreshTokens)
137+
138+### Header Options
139+
140+| Flag / Config Field | Type | Description | Default |
141+| ------------------------------------------------------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
142+| flag: `--basic-auth-password`<br/>toml: `basic_auth_password` | string | the password to set when passing the HTTP Basic Auth header | |
143+| flag: `--set-xauthrequest`<br/>toml: `set_xauthrequest` | bool | set X-Auth-Request-User, X-Auth-Request-Groups, X-Auth-Request-Email and X-Auth-Request-Preferred-Username response headers (useful in Nginx auth_request mode). When used with `--pass-access-token`, X-Auth-Request-Access-Token is added to response headers. | false |
144+| flag: `--set-authorization-header`<br/>toml: `set_authorization_header` | bool | set Authorization Bearer response header (useful in Nginx auth_request mode) | false |
145+| flag: `--set-basic-auth`<br/>toml: `set_basic_auth` | bool | set HTTP Basic Auth information in response (useful in Nginx auth_request mode) | false |
146+| flag: `--skip-auth-strip-headers`<br/>toml: `skip_auth_strip_headers` | bool | strips `X-Forwarded-*` style authentication headers & `Authorization` header if they would be set by oauth2-proxy | true |
147+| flag: `--pass-access-token`<br/>toml: `pass_access_token` | bool | pass OAuth access_token to upstream via X-Forwarded-Access-Token header. When used with `--set-xauthrequest` this adds the X-Auth-Request-Access-Token header to the response | false |
148+| flag: `--pass-authorization-header`<br/>toml: `pass_authorization_header` | bool | pass OIDC IDToken to upstream via Authorization Bearer header | false |
149+| flag: `--pass-basic-auth`<br/>toml: `pass_basic_auth` | bool | pass HTTP Basic Auth, X-Forwarded-User, X-Forwarded-Email and X-Forwarded-Preferred-Username information to upstream | true |
150+| flag: `--prefer-email-to-user`<br/>toml: `prefer_email_to_user` | bool | Prefer to use the Email address as the Username when passing information to upstream. Will only use Username if Email is unavailable, e.g. htaccess authentication. Used in conjunction with `--pass-basic-auth` and `--pass-user-headers` | false |
151+| flag: `--pass-user-headers`<br/>toml: `pass_user_headers` | bool | pass X-Forwarded-User, X-Forwarded-Groups, X-Forwarded-Email and X-Forwarded-Preferred-Username information to upstream | true |
152+
153+### Logging Options
154+
155+| Flag / Config Field | Type | Description | Default |
156+| --------------------------------------------------------------------- | ------ | ---------------------------------------------------------------------------- | --------------------------------------------------- |
157+| flag: `--auth-logging-format`<br/>toml: `auth_logging_format` | string | Template for authentication log lines | see [Logging Configuration](#logging-configuration) |
158+| flag: `--auth-logging`<br/>toml: `auth_logging` | bool | Log authentication attempts | true |
159+| flag: `--errors-to-info-log`<br/>toml: `errors_to_info_log` | bool | redirects error-level logging to default log channel instead of stderr | false |
160+| flag: `--exclude-logging-path`<br/>toml: `exclude_logging_paths` | string | comma separated list of paths to exclude from logging, e.g. `"/ping,/path2"` | `""` (no paths excluded) |
161+| flag: `--logging-compress`<br/>toml: `logging_compress` | bool | Should rotated log files be compressed using gzip | false |
162+| flag: `--logging-filename`<br/>toml: `logging_filename` | string | File to log requests to, empty for `stdout` | `""` (stdout) |
163+| flag: `--logging-local-time`<br/>toml: `logging_local_time` | bool | Use local time in log files and backup filenames instead of UTC | true (local time) |
164+| flag: `--logging-max-age`<br/>toml: `logging_max_age` | int | Maximum number of days to retain old log files | 7 |
165+| flag: `--logging-max-backups`<br/>toml: `logging_max_backups` | int | Maximum number of old log files to retain; 0 to disable | 0 |
166+| flag: `--logging-max-size`<br/>toml: `logging_max_size` | int | Maximum size in megabytes of the log file before rotation | 100 |
167+| flag: `--request-id-header`<br/>toml: `request_id_header` | string | Request header to use as the request ID in logging | X-Request-Id |
168+| flag: `--request-logging-format`<br/>toml: `request_logging_format` | string | Template for request log lines | see [Logging Configuration](#logging-configuration) |
169+| flag: `--request-logging`<br/>toml: `request_logging` | bool | Log requests | true |
170+| flag: `--silence-ping-logging`<br/>toml: `silence_ping_logging` | bool | disable logging of requests to ping & ready endpoints | false |
171+| flag: `--standard-logging-format`<br/>toml: `standard_logging_format` | string | Template for standard log lines | see [Logging Configuration](#logging-configuration) |
172+| flag: `--standard-logging`<br/>toml: `standard_logging` | bool | Log standard runtime information | true |
173+
174+### Page Template Options
175+
176+| Flag / Config Field | Type | Description | Default |
177+| ----------------------------------------------------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------- | ------- |
178+| flag: `--banner`<br/>toml: `banner` | string | custom (html) banner string. Use `"-"` to disable default banner. | |
179+| flag: `--custom-sign-in-logo`<br/>toml: `custom_sign_in_logo` | string | path or a URL to an custom image for the sign_in page logo. Use `"-"` to disable default logo. | |
180+| flag: `--custom-templates-dir`<br/>toml: `custom_templates_dir` | string | path to custom html templates | |
181+| flag: `--display-htpasswd-form`<br/>toml: `display_htpasswd_form` | bool | display username / password login form if an htpasswd file is provided | true |
182+| flag: `--footer`<br/>toml: `footer` | string | custom (html) footer string. Use `"-"` to disable default footer. (Can be used to obfuscate the version) | |
183+| flag: `--show-debug-on-error`<br/>toml: `show_debug_on_error` | bool | show detailed error information on error pages (WARNING: this may contain sensitive information - do not use in production) | false |
184+
185+### Probe Options
186+
187+| Flag / Config Field | Type | Description | Default |
188+| ------------------------------------------------------- | ------ | ---------------------------------------------------------- | ----------------------------- |
189+| flag: `--ping-path`<br/>toml: `ping_path` | string | the ping endpoint that can be used for basic health checks | `"/ping"` |
190+| flag: `--ping-user-agent`<br/>toml: `ping_user_agent` | string | a User-Agent that can be used for basic health checks | `""` (don't check user agent) |
191+| flag: `--ready-path`<br/>toml: `ready_path` | string | the ready endpoint that can be used for deep health checks | `"/ready"` |
192+| flag: `--gcp-healthchecks`<br/>toml: `gcp_healthchecks` | bool | Enable GCP/GKE healthcheck endpoints (deprecated) | false |
193+
194+### Proxy Options
195+
196+:::warning
197+When `--reverse-proxy` is enabled, configure `--trusted-proxy-ip` to the IPs or CIDR ranges of the reverse proxies that are allowed to send `X-Forwarded-*` headers. If you leave it unset, OAuth2 Proxy currently trusts all source IPs for backwards compatibility, which means a client that can reach OAuth2 Proxy directly may be able to spoof forwarded headers.
198+:::
199+
200+| Flag / Config Field | Type | Description | Default |
201+| ----------------------------------------------------------------------------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- |
202+| flag: `--allow-query-semicolons`<br/>toml: `allow_query_semicolons` | bool | allow the use of semicolons in query args ([required for some legacy applications](https://github.com/golang/go/issues/25192)) | `false` |
203+| flag: `--api-route`<br/>toml: `api_routes` | string \| list | Requests to these paths must already be authenticated with a cookie, or a JWT if `--skip-jwt-bearer-tokens` is set. No redirect to login will be done. Return 401 if not. Format: path_regex | |
204+| flag: `--authenticated-emails-file`<br/>toml: `authenticated_emails_file` | string | authenticate against emails via file (one per line) | |
205+| flag: `--bearer-token-login-fallback`<br/>toml: `bearer_token_login_fallback` | bool | if `--skip-jwt-bearer-tokens` is set, if a request includes an invalid JWT (expired, malformed, missing required audiences, etc), fall back to normal login redirect as if the token were not sent at all. If false, respond 403 | true |
206+| flag: `--email-domain`<br/>toml: `email_domains` | string \| list | authenticate emails with the specified domain (may be given multiple times). Use `*` to authenticate any email | |
207+| flag: `--encode-state`<br/>toml: `encode_state` | bool | encode the state parameter as UrlEncodedBase64 | false |
208+| flag: `--extra-jwt-issuers`<br/>toml: `extra_jwt_issuers` | string | if `--skip-jwt-bearer-tokens` is set, a list of extra JWT `issuer=audience` (see a token's `iss`, `aud` fields) pairs (where the issuer URL has a `.well-known/openid-configuration` or a `.well-known/jwks.json`) | |
209+| flag: `--force-https`<br/>toml: `force_https` | bool | enforce https redirect | `false` |
210+| flag: `--force-json-errors`<br/>toml: `force_json_errors` | bool | force JSON errors instead of HTTP error pages or redirects | `false` |
211+| flag: `--htpasswd-file`<br/>toml: `htpasswd_file` | string | additionally authenticate against a htpasswd file. Entries must be created with `htpasswd -B` for bcrypt encryption | |
212+| flag: `--htpasswd-user-group`<br/>toml: `htpasswd_user_groups` | string \| list | the groups to be set on sessions for htpasswd users | |
213+| flag: `--proxy-prefix`<br/>toml: `proxy_prefix` | string | the url root path that this proxy should be nested under (e.g. /`<oauth2>/sign_in`) | `"/oauth2"` |
214+| flag: `--real-client-ip-header`<br/>toml: `real_client_ip_header` | string | Header used to determine the real IP of the client, requires `--reverse-proxy` to be set (one of: X-Forwarded-For, X-Real-IP, X-ProxyUser-IP, X-Envoy-External-Address, or CF-Connecting-IP) | X-Real-IP |
215+| flag: `--redirect-url`<br/>toml: `redirect_url` | string | the OAuth Redirect URL, e.g. `"https://internalapp.yourcompany.com/oauth2/callback"` | |
216+| flag: `--relative-redirect-url`<br/>toml: `relative_redirect_url` | bool | allow relative OAuth Redirect URL.` | false |
217+| flag: `--reverse-proxy`<br/>toml: `reverse_proxy` | bool | are we running behind a reverse proxy, controls whether headers like X-Real-IP are accepted and allows X-Forwarded-\{Proto,Host,Uri\} headers to be used on redirect selection | false |
218+| flag: `--trusted-proxy-ip`<br/>toml: `trusted_proxy_ips` | string \| list | list of IPs or CIDR ranges allowed to supply `X-Forwarded-*` headers when `--reverse-proxy` is enabled. If not set, OAuth2 Proxy preserves backwards compatibility by trusting all source IPs (`0.0.0.0/0`, `::/0`) and logs a warning at startup. Configure this to your reverse proxy addresses to prevent forwarded header spoofing. | `"0.0.0.0/0", "::/0"` |
219+| flag: `--signature-key`<br/>toml: `signature_key` | string | GAP-Signature request signature key (algorithm:secretkey) | |
220+| flag: `--skip-auth-preflight`<br/>toml: `skip_auth_preflight` | bool | will skip authentication for OPTIONS requests | false |
221+| flag: `--skip-auth-regex`<br/>toml: `skip_auth_regex` | string \| list | (DEPRECATED for `--skip-auth-route`) bypass authentication for requests paths that match (may be given multiple times). Path matching is performed against the normalized path only; fragment identifiers (`#`) and their URL-encoded form (`%23`) are stripped before evaluation. | |
222+| flag: `--skip-auth-route`<br/>toml: `skip_auth_routes` | string \| list | bypass authentication for requests that match the method & path. Format: method=path_regex OR method!=path_regex. For all methods: path_regex OR !=path_regex. Path matching is performed against the normalized path only; fragment identifiers (`#`) and their URL-encoded form (`%23`) are stripped before evaluation. | |
223+| flag: `--skip-jwt-bearer-tokens`<br/>toml: `skip_jwt_bearer_tokens` | bool | will skip requests that have verified JWT bearer tokens (the token must have [`aud`](https://en.wikipedia.org/wiki/JSON_Web_Token#Standard_fields) that matches this client id or one of the extras from `extra-jwt-issuers`) | false |
224+| flag: `--skip-provider-button`<br/>toml: `skip_provider_button` | bool | will skip sign-in-page to directly reach the next step: oauth/start | false |
225+| flag: `--ssl-insecure-skip-verify`<br/>toml: `ssl_insecure_skip_verify` | bool | skip validation of certificates presented when using HTTPS providers | false |
226+| flag: `--trusted-ip`<br/>toml: `trusted_ips` | string \| list | list of IPs or CIDR ranges to allow to bypass authentication (may be given multiple times). When combined with `--reverse-proxy` and optionally `--real-client-ip-header` this will evaluate the trust of the IP stored in an HTTP header by a reverse proxy rather than the layer-3/4 remote address. WARNING: trusting IPs has inherent security flaws, especially when obtaining the IP address from an HTTP header (reverse-proxy mode). Use this option only if you understand the risks and how to manage them. | |
227+| flag: `--whitelist-domain`<br/>toml: `whitelist_domains` | string \| list | allowed domains for redirection after authentication. Prefix domain with a `.` or a `*.` to allow subdomains (e.g. `.example.com`, `*.example.com`)&nbsp;[^2] | |
228+
229+[^2]: When using the `whitelist-domain` option, any domain prefixed with a `.` or a `*.` will allow any subdomain of the specified domain as a valid redirect URL. By default, only empty ports are allowed. This translates to allowing the default port of the URL's protocol (80 for HTTP, 443 for HTTPS, etc.) since browsers omit them. To allow only a specific port, add it to the whitelisted domain: `example.com:8080`. To allow any port, use `*`: `example.com:*`.
230+
231+### Server Options
232+
233+| Flag / Config Field | Type | Description | Default |
234+| ------------------------------------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ |
235+| flag: `--http-address`<br/>toml: `http_address` | string | `[http://]<addr>:<port>` or `unix://<path>` or `fd:<int>` (case insensitive) to listen on for HTTP clients. Unix sockets are created with default system umask mode, which can be overridden, e.g. `unix://my-socket,mode=0777`. Square brackets are required for ipv6 address, e.g. `http://[::1]:4180` | `"127.0.0.1:4180"` |
236+| flag: `--https-address`<br/>toml: `https_address` | string | `[https://]<addr>:<port>` to listen on for HTTPS clients. Square brackets are required for ipv6 address, e.g. `https://[::1]:443` | `":443"` |
237+| flag: `--metrics-address`<br/>toml: `metrics_address` | string | the address prometheus metrics will be scraped from | `""` |
238+| flag: `--metrics-secure-address`<br/>toml: `metrics_secure_address` | string | the address prometheus metrics will be scraped from if using HTTPS | `""` |
239+| flag: `--metrics-tls-cert-file`<br/>toml: `metrics_tls_cert_file` | string | path to certificate file for secure metrics server | `""` |
240+| flag: `--metrics-tls-key-file`<br/>toml: `metrics_tls_key_file` | string | path to private key file for secure metrics server | `""` |
241+| flag: `--tls-cert-file`<br/>toml: `tls_cert_file` | string | path to certificate file | |
242+| flag: `--tls-key-file`<br/>toml: `tls_key_file` | string | path to private key file | |
243+| flag: `--tls-cipher-suite`<br/>toml: `tls_cipher_suites` | string \| list | Restricts TLS cipher suites used by server to those listed (e.g. TLS_RSA_WITH_RC4_128_SHA) (may be given multiple times). If not specified, the default Go safe cipher list is used. List of valid cipher suites can be found in the [crypto/tls documentation](https://pkg.go.dev/crypto/tls#pkg-constants). | |
244+| flag: `--tls-min-version`<br/>toml: `tls_min_version` | string | minimum TLS version that is acceptable, either `"TLS1.2"` or `"TLS1.3"` | `"TLS1.2"` |
245+
246+### Session Options
247+
248+| Flag / Config Field | Type | Description | Default |
249+| ----------------------------------------------------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
250+| flag: `--session-cookie-minimal`<br/>toml: `session_cookie_minimal` | bool | strip OAuth tokens from cookie session stores if they aren't needed (cookie session store only) | false |
251+| flag: `--session-store-type`<br/>toml: `session_store_type` | string | [Session data storage backend](sessions.md); redis or cookie | cookie |
252+| flag: `--redis-cluster-connection-urls`<br/>toml: `redis_cluster_connection_urls` | string \| list | List of Redis cluster connection URLs (e.g. `redis://HOST[:PORT]`). Used in conjunction with `--redis-use-cluster` | |
253+| flag: `--redis-connection-url`<br/>toml: `redis_connection_url` | string | URL of redis server for redis session storage (e.g. `redis://HOST[:PORT]`) | |
254+| flag: `--redis-ca-path`<br/>toml: `redis_ca_path` | string | Path to a CA certificates file that should be used when connecting to redis. If not specified, the system cert pool is used instead. | |
255+| flag: `--redis-insecure-skip-tls-verify`<br/>toml: `redis_insecure_skip_tls_verify` | bool | skip TLS verification when connecting to Redis | false |
256+| flag: `--redis-password`<br/>toml: `redis_password` | string | Redis password. Applicable for all Redis configurations. Will override any password set in `--redis-connection-url` | |
257+| flag: `--redis-sentinel-password`<br/>toml: `redis_sentinel_password` | string | Redis sentinel password. Used only for sentinel connection; any redis node passwords need to use `--redis-password` | |
258+| flag: `--redis-sentinel-master-name`<br/>toml: `redis_sentinel_master_name` | string | Redis sentinel master name. Used in conjunction with `--redis-use-sentinel` | |
259+| flag: `--redis-sentinel-connection-urls`<br/>toml: `redis_sentinel_connection_urls` | string \| list | List of Redis sentinel connection URLs (e.g. `redis://HOST[:PORT]`). Used in conjunction with `--redis-use-sentinel` | |
260+| flag: `--redis-use-cluster`<br/>toml: `redis_use_cluster` | bool | Connect to redis cluster. Must set `--redis-cluster-connection-urls` to use this feature | false |
261+| flag: `--redis-use-sentinel`<br/>toml: `redis_use_sentinel` | bool | Connect to redis via sentinels. Must set `--redis-sentinel-master-name` and `--redis-sentinel-connection-urls` to use this feature | false |
262+| flag: `--redis-connection-idle-timeout`<br/>toml: `redis_connection_idle_timeout` | int | Redis connection idle timeout seconds. If Redis [timeout](https://redis.io/docs/reference/clients/#client-timeouts) option is set to non-zero, the `--redis-connection-idle-timeout` must be less than Redis timeout option. Example: if either redis.conf includes `timeout 15` or using `CONFIG SET timeout 15` the `--redis-connection-idle-timeout` must be at least `--redis-connection-idle-timeout=14` | 0 |
263+
264+### Upstream Options
265+
266+| Flag / Config Field | Type | Description | Default |
267+| ----------------------------------------------------------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ | ------- |
268+| flag: `--flush-interval`<br/>toml: `flush_interval` | duration | period between flushing response buffers when streaming responses | `"1s"` |
269+| flag: `--pass-host-header`<br/>toml: `pass_host_header` | bool | pass the request Host Header to upstream | true |
270+| flag: `--proxy-websockets`<br/>toml: `proxy_websockets` | bool | enables WebSocket proxying | true |
271+| flag: `--ssl-upstream-insecure-skip-verify`<br/>toml: `ssl_upstream_insecure_skip_verify` | bool | skip validation of certificates presented when using HTTPS upstreams | false |
272+| flag: `--disable-keep-alives`<br/>toml: `disable_keep_alives` | bool | disable HTTP keep-alive connections to the upstream server | false |
273+| flag: `--upstream-timeout`<br/>toml: `upstream_timeout` | duration | maximum amount of time the server will wait for a response from the upstream | 30s |
274+| flag: `--upstream`<br/>toml: `upstreams` | string \| list | the http url(s) of the upstream endpoint, file:// paths for static files or `static://<status_code>` for static response. Routing is based on the path | |
275+
276+## Configuration Validation
277+
278+The `--config-test` flag validates your configuration file without starting the proxy server. This is useful for:
279+- **CI/CD pipelines**: Pre-deployment validation
280+- **Configuration management**: Testing before applying changes
281+- **Debugging**: Verifying syntax and required fields
282+
283+### Usage
284+
285+```bash
286+# Test legacy config
287+oauth2-proxy --config /etc/oauth2-proxy.cfg --config-test
288+
289+# Test alpha config
290+oauth2-proxy --config /etc/core.cfg --alpha-config /etc/alpha.yaml --config-test
291+
292+# CI/CD pre-deployment check
293+# Returns with exit code 1 if any validation errors occur
294+oauth2-proxy --config new-config.cfg --config-test
295+```
296+
297+### Exit Codes
298+
299+- **0**: Configuration is valid ✅
300+- **1**: Configuration is invalid (errors printed to stderr) ❌
301+
302+### Validation Coverage
303+
304+The `--config-test` flag performs the **same comprehensive validation** as normal startup, including:
305+- Required fields (client ID, client secret, cookie secret, etc.)
306+- Syntax validation (TOML/YAML parsing)
307+- Provider configuration
308+- Upstream server definitions
309+- Session store connectivity (e.g., Redis network checks if configured)
310+
311+**Note**: Cannot be combined with `--convert-config-to-alpha`.
312+
313+## Upstreams Configuration
220314
221315`oauth2-proxy` supports having multiple upstreams, and has the option to pass requests on to HTTP(S) servers, unix socket or serve static files from the file system.
222316
223−HTTP and HTTPS upstreams are configured by providing a URL such as `http://127.0.0.1:8080/` for the upstream parameter. . This will forward all authenticated requests to the upstream server. If you instead provide `http://127.0.0.1:8080/some/path/` then it will only be requests that start with `/some/path/` which are forwarded to the upstream.
317+To configure **HTTP and HTTPS upstreams**, provide such a URL in `--upstream=URL`. The scheme+host portion and the path portion are extracted to configure proxying behavior. When processing incoming requests, the path portion becomes a lookup key for selecting the destination server of the proxied request.
318+
319+* Upstream URLs *without a trailing slash,* like in `--upstream=http://service2.internal/foo`, will match an incoming request exactly to `/foo` in `https://this.o2p.example.com/foo`, and forward the request on to service2.internal, but not match a request to `https://this.o2p.example.com/foo/more` nor ...`.com/food`.
320+* Upstream URLs *with a trailing slash,* like in `--upstream=http://service1.internal/foo/`, will match any incoming request to any incoming requests's path *starting with* `/foo/`, like `/foo/` and `/foo/more` and `/foo/lots/more?etc`.
321+
322+If multiple `--upstream` URLs' paths match an incoming request, the one with the longest matching path (the most specific match) takes priority over shorter (less specific) ones.
224323
225−Unix socket upstreams are configured as `unix:///path/to/unix.sock`.
324+**Unix socket upstreams** are configured as `unix:///path/to/unix.sock`.
226325
227−Static file paths are configured as a file:// URL. `file:///var/www/static/` will serve the files from that directory at `http://[oauth2-proxy url]/var/www/static/`, which may not be what you want. You can provide the path to where the files should be available by adding a fragment to the configured URL. The value of the fragment will then be used to specify which path the files are available at, e.g. `file:///var/www/static/#/static/` will make `/var/www/static/` available at `http://[oauth2-proxy url]/static/`.
326+**Static file paths** are configured as a file:// URL. `file:///var/www/static/` will serve the files from that directory at `http://[oauth2-proxy url]/var/www/static/`, which may not be what you want. You can provide the path to where the files should be available by adding a fragment to the configured URL. The value of the fragment will then be used to specify which path the files are available at, e.g. `file:///var/www/static/#/static/` will make `/var/www/static/` available at `http://[oauth2-proxy url]/static/`.
228327
229328Multiple upstreams can either be configured by supplying a comma separated list to the `--upstream` parameter, supplying the parameter multiple times or providing a list in the [config file](#config-file). When multiple upstreams are used routing to them will be based on the path they are set up with.
230329
231−### Environment variables
330+## Environment variables
232331
233332Every command line argument can be specified as an environment variable by
234333prefixing it with `OAUTH2_PROXY_`, capitalising it, and replacing hyphens (`-`)
@@ -238,8 +337,15 @@ environment variable should be plural (trailing `S`).
238337This is particularly useful for storing secrets outside a configuration file
239338or the command line.
240339
241−For example, the `--cookie-secret` flag becomes `OAUTH2_PROXY_COOKIE_SECRET`,
242−and the `--email-domain` flag becomes `OAUTH2_PROXY_EMAIL_DOMAINS`.
340+For example, the `--cookie-secret` flag becomes `OAUTH2_PROXY_COOKIE_SECRET`.
341+If a flag has the type `string | list` like the `--email-domain` flag it is
342+available as an environment variable in plural form e.g. `OAUTH2_PROXY_EMAIL_DOMAINS`
343+
344+Values for type `string | list` usually have a plural environment variable name
345+and need to be seperated by `,` e.g.
346+`OAUTH2_PROXY_SKIP_AUTH_ROUTES="GET=^/api/status,POST=^/api/saved_objects/_import"`
347+
348+Please check the type for each [config option](#config-options) first.
243349
244350## Logging Configuration
245351
@@ -253,7 +359,8 @@ Each type of logging has its own configurable format and variables. By default,
253359
254360Logging of requests to the `/ping` endpoint (or using `--ping-user-agent`) and the `/ready` endpoint can be disabled with `--silence-ping-logging` reducing log volume.
255361
256−### Auth Log Format
362+## Auth Log Format
363+
257364Authentication logs are logs which are guaranteed to contain a username or email address of a user attempting to authenticate. These logs are output by default in the below format:
258365
259366```
@@ -275,20 +382,21 @@ The default format is configured as follows:
275382
276383Available variables for auth logging:
277384
278−| Variable | Example | Description |
279−| --- | --- | --- |
280−| Client | 74.125.224.72 | The client/remote IP address. Will use the X-Real-IP header it if exists & reverse-proxy is set to true. |
281−| Host | domain.com | The value of the Host header. |
282−| Message | Authenticated via OAuth2 | The details of the auth attempt. |
283−| Protocol | HTTP/1.0 | The request protocol. |
284−| RequestID | 00010203-0405-4607-8809-0a0b0c0d0e0f | The request ID pulled from the `--request-id-header`. Random UUID if empty |
285−| RequestMethod | GET | The request method. |
286−| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
287−| UserAgent | - | The full user agent as reported by the requesting client. |
288−| Username | username@email.com | The email or username of the auth request. |
289−| Status | AuthSuccess | The status of the auth request. See above for details. |
290−
291−### Request Log Format
385+| Variable | Example | Description |
386+| ------------- | ------------------------------------ | -------------------------------------------------------------------------------------------------------- |
387+| Client | 74.125.224.72 | The client/remote IP address. Will use the X-Real-IP header it if exists & reverse-proxy is set to true. |
388+| Host | domain.com | The value of the Host header. |
389+| Message | Authenticated via OAuth2 | The details of the auth attempt. |
390+| Protocol | HTTP/1.0 | The request protocol. |
391+| RequestID | 00010203-0405-4607-8809-0a0b0c0d0e0f | The request ID pulled from the `--request-id-header`. Random UUID if empty |
392+| RequestMethod | GET | The request method. |
393+| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
394+| UserAgent | - | The full user agent as reported by the requesting client. |
395+| Username | username@email.com | The email or username of the auth request. |
396+| Status | AuthSuccess | The status of the auth request. See above for details. |
397+
398+## Request Log Format
399+
292400HTTP request logs will output by default in the below format:
293401
294402```
@@ -304,23 +412,24 @@ The default format is configured as follows:
304412
305413Available variables for request logging:
306414
307−| Variable | Example | Description |
308−| --- | --- | --- |
309−| Client | 74.125.224.72 | The client/remote IP address. Will use the X-Real-IP header it if exists & reverse-proxy is set to true. |
310−| Host | domain.com | The value of the Host header. |
311−| Protocol | HTTP/1.0 | The request protocol. |
312−| RequestDuration | 0.001 | The time in seconds that a request took to process. |
313−| RequestID | 00010203-0405-4607-8809-0a0b0c0d0e0f | The request ID pulled from the `--request-id-header`. Random UUID if empty |
314−| RequestMethod | GET | The request method. |
315−| RequestURI | "/oauth2/auth" | The URI path of the request. |
316−| ResponseSize | 12 | The size in bytes of the response. |
317−| StatusCode | 200 | The HTTP status code of the response. |
318−| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
319−| Upstream | - | The upstream data of the HTTP request. |
320−| UserAgent | - | The full user agent as reported by the requesting client. |
321−| Username | username@email.com | The email or username of the auth request. |
322−
323−### Standard Log Format
415+| Variable | Example | Description |
416+| --------------- | ------------------------------------ | -------------------------------------------------------------------------------------------------------- |
417+| Client | 74.125.224.72 | The client/remote IP address. Will use the X-Real-IP header it if exists & reverse-proxy is set to true. |
418+| Host | domain.com | The value of the Host header. |
419+| Protocol | HTTP/1.0 | The request protocol. |
420+| RequestDuration | 0.001 | The time in seconds that a request took to process. |
421+| RequestID | 00010203-0405-4607-8809-0a0b0c0d0e0f | The request ID pulled from the `--request-id-header`. Random UUID if empty |
422+| RequestMethod | GET | The request method. |
423+| RequestURI | "/oauth2/auth" | The URI path of the request. |
424+| ResponseSize | 12 | The size in bytes of the response. |
425+| StatusCode | 200 | The HTTP status code of the response. |
426+| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
427+| Upstream | - | The upstream data of the HTTP request. |
428+| UserAgent | - | The full user agent as reported by the requesting client. |
429+| Username | username@email.com | The email or username of the auth request. |
430+
431+## Standard Log Format
432+
324433All other logging that is not covered by the above two types of logging will be output in this standard logging format. This includes configuration information at startup and errors that occur outside of a session. The default format is below:
325434
326435```
@@ -335,274 +444,8 @@ If you require a different format than that, you can configure it with the `--st
335444
336445Available variables for standard logging:
337446
338−| Variable | Example | Description |
339−| --- | --- | --- |
340−| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
341−| File | main.go:40 | The file and line number of the logging statement. |
342−| Message | HTTP: listening on 127.0.0.1:4180 | The details of the log statement. |
343−
344−## Configuring for use with the Nginx `auth_request` directive
345−
346−**This option requires `--reverse-proxy` option to be set.**
347−
348−The [Nginx `auth_request` directive](http://nginx.org/en/docs/http/ngx_http_auth_request_module.html) allows Nginx to authenticate requests via the oauth2-proxy's `/auth` endpoint, which only returns a 202 Accepted response or a 401 Unauthorized response without proxying the request through. For example:
349−
350−```nginx
351−server {
352− listen 443 ssl;
353− server_name ...;
354− include ssl/ssl.conf;
355−
356− location /oauth2/ {
357− proxy_pass http://127.0.0.1:4180;
358− proxy_set_header Host $host;
359− proxy_set_header X-Real-IP $remote_addr;
360− proxy_set_header X-Auth-Request-Redirect $request_uri;
361− # or, if you are handling multiple domains:
362− # proxy_set_header X-Auth-Request-Redirect $scheme://$host$request_uri;
363− }
364− location = /oauth2/auth {
365− proxy_pass http://127.0.0.1:4180;
366− proxy_set_header Host $host;
367− proxy_set_header X-Real-IP $remote_addr;
368− proxy_set_header X-Forwarded-Uri $request_uri;
369− # nginx auth_request includes headers but not body
370− proxy_set_header Content-Length "";
371− proxy_pass_request_body off;
372− }
373−
374− location / {
375− auth_request /oauth2/auth;
376− error_page 401 =403 /oauth2/sign_in;
377−
378− # pass information via X-User and X-Email headers to backend,
379− # requires running with --set-xauthrequest flag
380− auth_request_set $user $upstream_http_x_auth_request_user;
381− auth_request_set $email $upstream_http_x_auth_request_email;
382− proxy_set_header X-User $user;
383− proxy_set_header X-Email $email;
384−
385− # if you enabled --pass-access-token, this will pass the token to the backend
386− auth_request_set $token $upstream_http_x_auth_request_access_token;
387− proxy_set_header X-Access-Token $token;
388−
389− # if you enabled --cookie-refresh, this is needed for it to work with auth_request
390− auth_request_set $auth_cookie $upstream_http_set_cookie;
391− add_header Set-Cookie $auth_cookie;
392−
393− # When using the --set-authorization-header flag, some provider's cookies can exceed the 4kb
394− # limit and so the OAuth2 Proxy splits these into multiple parts.
395− # Nginx normally only copies the first `Set-Cookie` header from the auth_request to the response,
396− # so if your cookies are larger than 4kb, you will need to extract additional cookies manually.
397− auth_request_set $auth_cookie_name_upstream_1 $upstream_cookie_auth_cookie_name_1;
398−
399− # Extract the Cookie attributes from the first Set-Cookie header and append them
400− # to the second part ($upstream_cookie_* variables only contain the raw cookie content)
401− if ($auth_cookie ~* "(; .*)") {
402− set $auth_cookie_name_0 $auth_cookie;
403− set $auth_cookie_name_1 "auth_cookie_name_1=$auth_cookie_name_upstream_1$1";
404− }
405−
406− # Send both Set-Cookie headers now if there was a second part
407− if ($auth_cookie_name_upstream_1) {
408− add_header Set-Cookie $auth_cookie_name_0;
409− add_header Set-Cookie $auth_cookie_name_1;
410− }
411−
412− proxy_pass http://backend/;
413− # or "root /path/to/site;" or "fastcgi_pass ..." etc
414− }
415−}
416−```
417−
418−When you use ingress-nginx in Kubernetes, you MUST use `kubernetes/ingress-nginx` (which includes the Lua module) and the following configuration snippet for your `Ingress`.
419−Variables set with `auth_request_set` are not `set`-able in plain nginx config when the location is processed via `proxy_pass` and then may only be processed by Lua.
420−Note that `nginxinc/kubernetes-ingress` does not include the Lua module.
421−
422−```yaml
423−nginx.ingress.kubernetes.io/auth-response-headers: Authorization
424−nginx.ingress.kubernetes.io/auth-signin: https://$host/oauth2/start?rd=$escaped_request_uri
425−nginx.ingress.kubernetes.io/auth-url: https://$host/oauth2/auth
426−nginx.ingress.kubernetes.io/configuration-snippet: |
427− auth_request_set $name_upstream_1 $upstream_cookie_name_1;
428−
429− access_by_lua_block {
430− if ngx.var.name_upstream_1 ~= "" then
431− ngx.header["Set-Cookie"] = "name_1=" .. ngx.var.name_upstream_1 .. ngx.var.auth_cookie:match("(; .*)")
432− end
433− }
434−```
435−It is recommended to use `--session-store-type=redis` when expecting large sessions/OIDC tokens (_e.g._ with MS Azure).
436−
437−You have to substitute *name* with the actual cookie name you configured via --cookie-name parameter. If you don't set a custom cookie name the variable should be "$upstream_cookie__oauth2_proxy_1" instead of "$upstream_cookie_name_1" and the new cookie-name should be "_oauth2_proxy_1=" instead of "name_1=".
438−
439−## Configuring for use with the Traefik (v2) `ForwardAuth` middleware
440−
441−**This option requires `--reverse-proxy` option to be set.**
442−
443−### ForwardAuth with 401 errors middleware
444−
445−The [Traefik v2 `ForwardAuth` middleware](https://doc.traefik.io/traefik/middlewares/forwardauth/) allows Traefik to authenticate requests via the oauth2-proxy's `/oauth2/auth` endpoint on every request, which only returns a 202 Accepted response or a 401 Unauthorized response without proxying the whole request through. For example, on Dynamic File (YAML) Configuration:
446−
447−```yaml
448−http:
449− routers:
450− a-service:
451− rule: "Host(`a-service.example.com`)"
452− service: a-service-backend
453− middlewares:
454− - oauth-errors
455− - oauth-auth
456− tls:
457− certResolver: default
458− domains:
459− - main: "example.com"
460− sans:
461− - "*.example.com"
462− oauth:
463− rule: "Host(`a-service.example.com`, `oauth.example.com`) && PathPrefix(`/oauth2/`)"
464− middlewares:
465− - auth-headers
466− service: oauth-backend
467− tls:
468− certResolver: default
469− domains:
470− - main: "example.com"
471− sans:
472− - "*.example.com"
473−
474− services:
475− a-service-backend:
476− loadBalancer:
477− servers:
478− - url: http://172.16.0.2:7555
479− oauth-backend:
480− loadBalancer:
481− servers:
482− - url: http://172.16.0.1:4180
483−
484− middlewares:
485− auth-headers:
486− headers:
487− sslRedirect: true
488− stsSeconds: 315360000
489− browserXssFilter: true
490− contentTypeNosniff: true
491− forceSTSHeader: true
492− sslHost: example.com
493− stsIncludeSubdomains: true
494− stsPreload: true
495− frameDeny: true
496− oauth-auth:
497− forwardAuth:
498− address: https://oauth.example.com/oauth2/auth
499− trustForwardHeader: true
500− oauth-errors:
501− errors:
502− status:
503− - "401-403"
504− service: oauth-backend
505− query: "/oauth2/sign_in?rd={url}"
506−```
507−
508−### ForwardAuth with static upstreams configuration
509−
510−Redirect to sign_in functionality provided without the use of `errors` middleware with [Traefik v2 `ForwardAuth` middleware](https://doc.traefik.io/traefik/middlewares/forwardauth/) pointing to oauth2-proxy service's `/` endpoint
511−
512−**Following options need to be set on `oauth2-proxy`:**
513−- `--upstream=static://202`: Configures a static response for authenticated sessions
514−- `--reverse-proxy=true`: Enables the use of `X-Forwarded-*` headers to determine redirects correctly
515−
516−```yaml
517−http:
518− routers:
519− a-service-route-1:
520− rule: "Host(`a-service.example.com`, `b-service.example.com`) && PathPrefix(`/`)"
521− service: a-service-backend
522− middlewares:
523− - oauth-auth-redirect # redirects all unauthenticated to oauth2 signin
524− tls:
525− certResolver: default
526− domains:
527− - main: "example.com"
528− sans:
529− - "*.example.com"
530− a-service-route-2:
531− rule: "Host(`a-service.example.com`) && PathPrefix(`/no-auto-redirect`)"
532− service: a-service-backend
533− middlewares:
534− - oauth-auth-wo-redirect # unauthenticated session will return a 401
535− tls:
536− certResolver: default
537− domains:
538− - main: "example.com"
539− sans:
540− - "*.example.com"
541− services-oauth2-route:
542− rule: "Host(`a-service.example.com`, `b-service.example.com`) && PathPrefix(`/oauth2/`)"
543− middlewares:
544− - auth-headers
545− service: oauth-backend
546− tls:
547− certResolver: default
548− domains:
549− - main: "example.com"
550− sans:
551− - "*.example.com"
552− oauth2-proxy-route:
553− rule: "Host(`oauth.example.com`) && PathPrefix(`/`)"
554− middlewares:
555− - auth-headers
556− service: oauth-backend
557− tls:
558− certResolver: default
559− domains:
560− - main: "example.com"
561− sans:
562− - "*.example.com"
563−
564− services:
565− a-service-backend:
566− loadBalancer:
567− servers:
568− - url: http://172.16.0.2:7555
569− b-service-backend:
570− loadBalancer:
571− servers:
572− - url: http://172.16.0.3:7555
573− oauth-backend:
574− loadBalancer:
575− servers:
576− - url: http://172.16.0.1:4180
577−
578− middlewares:
579− auth-headers:
580− headers:
581− sslRedirect: true
582− stsSeconds: 315360000
583− browserXssFilter: true
584− contentTypeNosniff: true
585− forceSTSHeader: true
586− sslHost: example.com
587− stsIncludeSubdomains: true
588− stsPreload: true
589− frameDeny: true
590− oauth-auth-redirect:
591− forwardAuth:
592− address: https://oauth.example.com/
593− trustForwardHeader: true
594− authResponseHeaders:
595− - X-Auth-Request-Access-Token
596− - Authorization
597− oauth-auth-wo-redirect:
598− forwardAuth:
599− address: https://oauth.example.com/oauth2/auth
600− trustForwardHeader: true
601− authResponseHeaders:
602− - X-Auth-Request-Access-Token
603− - Authorization
604−```
605−
606−:::note
607−If you set up your OAuth2 provider to rotate your client secret, you can use the `client-secret-file` option to reload the secret when it is updated.
608−:::
447+| Variable | Example | Description |
448+| --------- | --------------------------------- | -------------------------------------------------- |
449+| Timestamp | 2015/03/19 17:20:19 | The date and time of the logging event. |
450+| File | main.go:40 | The file and line number of the logging statement. |
451+| Message | HTTP: listening on 127.0.0.1:4180 | The details of the log statement. |
docs/docs/configuration/providers/atlassian.mdnew file+26
@@ -0,0 +1,26 @@
1+---
2+id: atlassian
3+title: Atlassian Cloud
4+---
5+
6+1. Create an OAuth 2.0 integration in the [Atlassian developer console](https://developer.atlassian.com/console/myapps/).
7+2. Under **Permissions**, add the User identity API with the `read:me` scope.
8+3. Under **Authorization**, set the callback URL to `https://<proxy_host>/oauth2/callback`.
9+4. Copy the client ID and secret from **Settings**.
10+5. Run the proxy with:
11+
12+```shell
13+ --provider=atlassian
14+ --client-id=<client ID>
15+ --client-secret=<secret>
16+ --redirect-url=https://<proxy_host>/oauth2/callback
17+ --cookie-secret=<cookie secret>
18+```
19+
20+A new app works only for the account that created it. Enable sharing under **Distribution** to let other users sign in.
21+Atlassian then admits only accounts with access to the Atlassian site the app is installed on; others are refused at
22+the consent screen.
23+
24+The proxy reads the user's email from `https://api.atlassian.com/me`. Restricting access further is supported by
25+[email](index.md#email-authentication). With `--cookie-refresh` set, the proxy re-validates the token against `/me` on
26+that interval.
docs/docs/configuration/providers/azure_ad.mddeleted−9
@@ -1,9 +0,0 @@
1−---
2−id: azure_ad
3−title: Microsoft Azure AD
4−---
5−
6−For adding an application to the Microsoft Azure AD follow [these steps to add an application](https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app).
7−
8−Take note of your `TenantId` if applicable for your situation. The `TenantId` can be used to override the default
9−`common` authorization server with a tenant specific server.
docs/docs/configuration/providers/cidaas.mdnew file+37
@@ -0,0 +1,37 @@
1+---
2+id: cidaas
3+title: Cidaas
4+---
5+
6+[Cidaas](https://www.cidaas.com/) is an Identity as a Service (IDaaS) solution that provides authentication and authorization services.
7+It supports various protocols including OpenID Connect, OAuth 2.0, and SAML.
8+
9+However, Cidaas provides groups and their roles as hierarchical claims, which are not supported by oauth2-proxy yet.
10+The Cidaas provider transforms the hierarchical claims into a flat list of groups, which can be used by oauth2-proxy.
11+
12+Example of groups and roles in Cidaas:
13+
14+```json
15+{
16+ "groups": [
17+ {
18+ "groupId": "group1",
19+ "roles": ["role1", "role2"]
20+ },
21+ {
22+ "groupId": "group2",
23+ "roles": ["role3"]
24+ }
25+ ]
26+}
27+```
28+
29+This will be transformed into a flat list of groups:
30+
31+```json
32+{
33+ "groups": ["group1:role1", "group2:role2", "group2:role3"]
34+}
35+```
36+
37+Apart from that the Cidaas provider inherits all the features of the [OpenID Connect provider](openid_connect.md).
docs/docs/configuration/providers/cisco_duo.mdnew file+44
@@ -0,0 +1,44 @@
1+---
2+id: cisco_duo
3+title: Cisco Duo
4+---
5+
6+Cisco Duo SSO can be configured with OAuth2 Proxy using the OIDC provider.
7+
8+1. Create a new **Generic OIDC Relying Party - Single Sign-On** application in the Duo Admin Portal
9+2. Configure OAuth2 Proxy with the following options:
10+
11+```
12+provider = "oidc"
13+provider_display_name = "Duo SSO"
14+scope = "openid email profile"
15+pass_access_token = true
16+code_challenge_method = "S256"
17+```
18+
19+3. Configure Provider endpoints. Copy the following values from the corresponding fields in the Duo Admin Portal:
20+
21+```
22+# Copy from "Client ID" field
23+client_id = "XXXXXXXX"
24+
25+# Copy from "Client Secret" field
26+client_secret = "XXXXXXXX"
27+
28+# Copy from "Issuer" field
29+oidc_issuer_url = "https://sso-xxxxxxxx.sso.duosecurity.com/oidc/xxxxxxxx"
30+
31+# Copy from "JWKS URL" field
32+oidc_jwks_url = "https://sso-xxxxxxxx.sso.duosecurity.com/oidc/xxxxxxxx/jwks"
33+
34+# Copy from "Token Introspection URL" field
35+validate_url = "https://sso-xxxxxxxx.sso.duosecurity.com/oidc/xxxxxxxx/token_introspection"
36+
37+# Copy from "UserInfo" field
38+profile_url = "https://sso-xxxxxxxx.sso.duosecurity.com/oidc/xxxxxxxx/userinfo"
39+
40+# Copy from "Token URL" field
41+redeem_url = "https://sso-xxxxxxxx.sso.duosecurity.com/oidc/xxxxxxxx/token"
42+```
43+
44+4. Complete Configuration by filling in any remaining required fields and save your configuration.
docs/docs/configuration/providers/dtt_sso.mdnew file+45
@@ -0,0 +1,45 @@
1+---
2+id: dtt_sso
3+title: DTT SSO
4+---
5+
6+Signs users in with the DTT SSO (auth-server) using the authorization code flow and its HS256 id_token.
7+
8+1. Register a client in the auth-server config, one per protected service, with the proxy's callback as its
9+ only redirect URI:
10+
11+ ```yaml
12+ clients:
13+ redash-gate:
14+ secret: <random secret>
15+ redirect_uri: https://redash.example.com/oauth2/callback
16+ display_name: Redash
17+ ```
18+
19+2. Run the proxy with:
20+
21+ ```shell
22+ --provider=dtt-sso
23+ --client-id=redash-gate
24+ --client-secret-file=/run/secrets/client_secret
25+ --redirect-url=https://redash.example.com/oauth2/callback
26+ --cookie-secret-file=/run/secrets/cookie_secret
27+ --cookie-name=_dtt_sso_redash
28+ --cookie-refresh=5m
29+ ```
30+
31+ Give each instance its own `--cookie-name`: another oauth2-proxy setting its cookie on a parent domain
32+ (the Atlassian proxy uses `_oauth2_proxy` on `.thebestagent.pro`) would otherwise shadow this one.
33+
34+The endpoints default to `https://auth.thebestagent.pro`. For another SSO host set `--login-url`, `--redeem-url`
35+and `--validate-url` to its `/oauth/authorize`, `/oauth/token` and `/oauth/check_token`; the id_token issuer must
36+equal the login URL's origin (the SSO's `site_host`).
37+
38+The scope must stay `openid`, the only scope the SSO accepts.
39+
40+The session carries the SSO `email`, the user UUID as the user, and the SSO `role` as the only group, so
41+`--allowed-group=dtt_admin` restricts access by role. `--authenticated-emails-file` and `--email-domain` restrict
42+by email as usual.
43+
44+With `--cookie-refresh` set, the proxy refreshes the tokens on that interval and re-reads the email and role; a user
45+deleted or signed out in the SSO loses access at the next refresh.
docs/docs/configuration/providers/gitea.md+5−1
@@ -1,8 +1,12 @@
11---
22id: gitea
3−title: Gitea
3+title: Gitea / Forgejo
44---
55
6+:::note
7+This is not actually a fully serparate provider. For more details and options please refer to the [GitHub Provider Options](github.md)
8+:::
9+
6101. Create a new application: `https://< your gitea host >/user/settings/applications`
7112. Under `Redirect URI` enter the correct URL i.e. `https://<proxied host>/oauth2/callback`
8123. Note the Client ID and Client Secret.
docs/docs/configuration/providers/github.md+35−9
@@ -3,6 +3,18 @@ id: github
33title: GitHub
44---
55
6+## Config Options
7+
8+| Flag | Toml Field | Type | Description | Default |
9+| ---------------- | -------------- | -------------- | ------------------------------------------------------------------------------------------------------------- | ------- |
10+| `--github-org` | `github_org` | string | restrict logins to members of this organisation | |
11+| `--github-team` | `github_team` | string | restrict logins to members of any of these teams (slug) or (org:team), comma separated | |
12+| `--github-repo` | `github_repo` | string | restrict logins to collaborators of this repository formatted as `orgname/repo` | |
13+| `--github-token` | `github_token` | string | the token to use when verifying repository collaborators (must have push access to the repository) | |
14+| `--github-user` | `github_users` | string \| list | To allow users to login by username even if they do not belong to the specified org and team or collaborators | |
15+
16+## Usage
17+
6181. Create a new project: https://github.com/settings/developers
7192. Under `Authorization callback URL` enter the correct url ie `https://internal.yourcompany.com/oauth2/callback`
820
@@ -12,23 +24,36 @@ team level access, or to collaborators of a repository. Restricting by these opt
1224NOTE: When `--github-user` is set, the specified users are allowed to log in even if they do not belong to the specified
1325org and team or collaborators.
1426
15−To restrict by organization only, include the following flag:
27+To restrict access to your organization:
28+
29+```shell
30+ # restrict logins to members of this organisation
31+ --github-org="your-org"
32+```
33+
34+To restrict access to specific teams within an organization:
1635
1736```shell
18− --github-org="" # restrict logins to members of this organisation
37+ --github-org="your-org"
38+ # restrict logins to members of any of these teams (slug), comma separated
39+ --github-team="team1,team2,team3"
1940```
2041
21−To restrict within an organization to specific teams, include the following flag in addition to `-github-org`:
42+To restrict to teams within different organizations, keep the organization flag empty and use `--github-team` like so:
2243
2344```shell
24− --github-team="" # restrict logins to members of any of these teams (slug), separated by a comma
45+ # keep empty
46+ --github-org=""
47+ # restrict logins to members to any of the following teams (format <org>:<slug>, like octo:team1), comma separated
48+ --github-team="org1:team1,org2:team1,org3:team42,octo:cat"
2549```
2650
2751If you would rather restrict access to collaborators of a repository, those users must either have push access to a
2852public repository or any access to a private repository:
2953
3054```shell
31− --github-repo="" # restrict logins to collaborators of this repository formatted as orgname/repo
55+ # restrict logins to collaborators of this repository formatted as orgname/repo
56+ --github-repo=""
3257```
3358
3459If you'd like to allow access to users with **read only** access to a **public** repository you will need to provide a
@@ -36,14 +61,15 @@ If you'd like to allow access to users with **read only** access to a **public**
3661created with at least the `public_repo` scope:
3762
3863```shell
39− --github-token="" # the token to use when verifying repository collaborators
64+ # the token to use when verifying repository collaborators
65+ --github-token=""
4066```
4167
42−To allow a user to log in with their username even if they do not belong to the specified org and team or collaborators,
43−separated by a comma
68+To allow a user to log in with their username even if they do not belong to the specified org and team or collaborators:
4469
4570```shell
46− --github-user="" #allow logins by username, separated by a comma
71+ # allow logins by username, comma separated
72+ --github-user=""
4773```
4874
4975If you are using GitHub enterprise, make sure you set the following to the appropriate url:
docs/docs/configuration/providers/gitlab.md+10−1
@@ -3,11 +3,20 @@ id: gitlab
33title: GitLab
44---
55
6+## Config Options
7+
8+| Flag | Toml Field | Type | Description | Default |
9+| ------------------- | ----------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
10+| `--gitlab-group` | `gitlab_groups` | string \| list | restrict logins to members of any of these groups (slug), separated by a comma | |
11+| `--gitlab-project` | `gitlab_projects` | string \| list | restrict logins to members of any of these projects (may be given multiple times) formatted as `orgname/repo=accesslevel`. Access level should be a value matching [Gitlab access levels](https://docs.gitlab.com/ee/api/members.html#valid-access-levels), defaulted to 20 if absent | |
12+
13+## Usage
14+
615This auth provider has been tested against Gitlab version 12.X. Due to Gitlab API changes, it may not work for version
716prior to 12.X (see [994](https://github.com/oauth2-proxy/oauth2-proxy/issues/994)).
817
918Whether you are using GitLab.com or self-hosting GitLab, follow
10−[these steps to add an application](https://docs.gitlab.com/ce/integration/oauth_provider.html). Make sure to enable at
19+[these steps to add an application](https://docs.gitlab.com/integration/oauth_provider/). Make sure to enable at
1120least the `openid`, `profile` and `email` scopes, and set the redirect url to your application url e.g.
1221https://myapp.com/oauth2/callback.
1322
docs/docs/configuration/providers/google.md+25−4
@@ -3,6 +3,20 @@ id: google
33title: Google (default)
44---
55
6+## Config Options
7+
8+| Flag | Toml Field | Type | Description | Default |
9+|-------------------------------------------------|----------------------------------------------| ------ |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------|
10+| `--google-admin-email` | `google_admin_email` | string | the google admin to impersonate for api calls | |
11+| `--google-group` | `google_groups` | string | restrict logins to members of this google group (may be given multiple times). If not specified and service account or default credentials are configured, all user groups will be allowed. | |
12+| `--google-service-account-json` | `google_service_account_json` | string | the path to the service account json credentials | |
13+| `--google-use-application-default-credentials` | `google_use_application_default_credentials` | bool | use application default credentials instead of service account json (i.e. GKE Workload Identity) | |
14+| `--google-target-principal` | `google_target_principal` | bool | the target principal to impersonate when using ADC | defaults to the service account configured for ADC |
15+| `--google-use-organization-id` | `google_use_organization_id` | bool | use organization id as preferred username | false |
16+| `--google-admin-api-user-scope` | `google_admin_api_user_scope` | string | the OAuth scope to use when querying the Google Admin SDK for organization id, can be 'readonly', 'user' or 'cloud'<br/> | `readonly` |
17+
18+## Usage
19+
620For Google, the registration steps are:
721
8221. Create a new project: https://console.developers.google.com/project
@@ -25,18 +39,17 @@ account is still authorized.
2539
2640#### Restrict auth to specific Google groups on your domain. (optional)
2741
28−1. Create a [service account](https://developers.google.com/identity/protocols/OAuth2ServiceAccount) and configure it
42+1. Create a [service account](https://developers.google.com/identity/protocols/oauth2/service-account) and configure it
2943 to use [Application Default Credentials / Workload Identity / Workload Identity Federation (recommended)](#using-application-default-credentials-adc--workload-identity--workload-identity-federation-recommended) or,
3044 alternatively download the JSON.
31452. Make note of the Client ID for a future step.
32463. Under "APIs & Auth", choose APIs.
33474. Click on Admin SDK and then Enable API.
34−5. Follow the steps on https://developers.google.com/admin-sdk/directory/v1/guides/delegation#delegate_domain-wide_authority_to_your_service_account
48+5. Follow the steps on [Set up domain-wide delegation for a service account](https://developers.google.com/workspace/guides/create-credentials#optional_set_up_domain-wide_delegation_for_a_service_account)
3549 and give the client id from step 2 the following oauth scopes:
3650
3751 ```
38− https://www.googleapis.com/auth/admin.directory.group.readonly
39− https://www.googleapis.com/auth/admin.directory.user.readonly
52+ https://www.googleapis.com/auth/admin.directory.group.member.readonly
4053 ```
4154
42556. Follow the steps on https://support.google.com/a/answer/60757 to enable Admin API access.
@@ -47,6 +60,7 @@ account is still authorized.
4760 of this flag with different groups and the user will be checked against all the provided groups.
4861
4962(Only if using a JSON file (see step 1))
63+
50649. Lock down the permissions on the json file downloaded from step 1 so only oauth2-proxy is able to read the file and
5165 set the path to the file in the `google-service-account-json` flag.
526610. Restart oauth2-proxy.
@@ -61,3 +75,10 @@ can be leveraged through a feature called Workload Identity. Follow Google's [gu
6175to set up Workload Identity.
6276
6377When deployed outside of GCP, [Workload Identity Federation](https://cloud.google.com/docs/authentication/provide-credentials-adc#wlif) might be an option.
78+
79+##### Using Organization ID as Preferred Username (optional)
80+By default, the google provider uses the google id as username. If you would like to use an organization id instead, you can set the `google-use-organization-id` flag to true.
81+This requires that the service account used to query the Google Admin SDK has one of the following scopes granted in step 5 above:
82+- `https://www.googleapis.com/auth/admin.directory.user.readonly`,
83+- `https://www.googleapis.com/auth/admin.directory.user`
84+- `https://www.googleapis.com/auth/cloud-platform`
docs/docs/configuration/providers/index.md+15−9
@@ -8,23 +8,29 @@ with Redirect URI(s) for the domain you intend to run `oauth2-proxy` on.
88
99Valid providers are :
1010
11−- [Google](google.md) _default_
12−- [Azure](azure.md)
1311- [ADFS](adfs.md)
12+- [Atlassian Cloud](atlassian.md)
13+- [Bitbucket](bitbucket.md)
14+- [Cidaas](cidaas.md)
15+- [CiscoDuo](cisco_duo.md)
16+- [DigitalOcean](digitalocean.md)
17+- [DTT SSO](dtt_sso.md)
1418- [Facebook](facebook.md)
15−- [GitHub](github.md)
1619- [Gitea](gitea.md)
17−- [Keycloak](keycloak.md)/[Keycloak OIDC](keycloak_oidc.md)
20+- [GitHub](github.md)
1821- [GitLab](gitlab.md)
22+- [Google](google.md) _default_
23+- [Keycloak](keycloak.md) (Deprecated)
24+- [Keycloak OIDC](keycloak_oidc.md)
1925- [LinkedIn](linkedin.md)
20−- [Microsoft Azure AD](azure_ad.md)
21−- [OpenID Connect](openid_connect.md)
2226- [login.gov](login_gov.md)
27+- [Microsoft Azure](ms_azure_ad.md) (Deprecated)
28+- [Microsoft Entra ID](ms_entra_id.md)
2329- [Nextcloud](nextcloud.md)
24−- [DigitalOcean](digitalocean.md)
25−- [Bitbucket](bitbucket.md)
30+- [OpenID Connect](openid_connect.md)
31+- [SourceHut](sourcehut.md)
2632
27−The provider can be selected using the `provider` configuration value.
33+The provider can be selected using the `provider` configuration value, or set in the [`providers` array using AlphaConfig](https://oauth2-proxy.github.io/oauth2-proxy/configuration/alpha-config#providers). However, [**the feature to implement multiple providers is not complete**](https://github.com/oauth2-proxy/oauth2-proxy/issues/926).
2834
2935Please note that not all providers support all claims. The `preferred_username` claim is currently only supported by the
3036OpenID Connect provider.
docs/docs/configuration/providers/keycloak.md+2−2
@@ -1,10 +1,10 @@
11---
22id: keycloak
3−title: Keycloak
3+title: Keycloak (Deprecated)
44---
55
66:::note
7−This is the legacy provider for Keycloak, use [Keycloak OIDC Auth Provider](keycloak_oidc.md) if possible.
7+This is the legacy and deprecated provider for Keycloak, use [Keycloak OIDC Auth Provider](keycloak_oidc.md) if possible.
88:::
99
10101. Create new client in your Keycloak realm with **Access Type** 'confidential' and **Valid Redirect URIs** 'https://internal.yourcompany.com/oauth2/callback'
docs/docs/configuration/providers/keycloak_oidc.md+8
@@ -3,6 +3,14 @@ id: keycloak_oidc
33title: Keycloak OIDC
44---
55
6+## Config Options
7+
8+| Flag | Toml Field | Type | Description | Default |
9+| ---------------- | --------------- | -------------- | ------------------------------------------------------------------------------------------------------------------ | ------- |
10+| `--allowed-role` | `allowed_roles` | string \| list | restrict logins to users with this role (may be given multiple times). Only works with the keycloak-oidc provider. | |
11+
12+## Usage
13+
614```
715 --provider=keycloak-oidc
816 --client-id=<your client's id>
docs/docs/configuration/providers/ms_azure_ad.mdnew file+59
@@ -0,0 +1,59 @@
1+---
2+id: azure
3+title: Azure (Deprecated)
4+---
5+
6+:::note
7+This is the legacy and deprecated provider for Azure, use [Microsoft Entra ID](ms_entra_id.md) if possible.
8+:::
9+
10+## Config Options
11+
12+| Flag | Toml Field | Type | Description | Default |
13+| ---------------- | -------------- | ------ | ---------------------------------------------------------------- | ---------- |
14+| `--azure-tenant` | `azure_tenant` | string | go to a tenant-specific or common (tenant-independent) endpoint. | `"common"` |
15+| `--resource` | `resource` | string | The resource that is protected (Azure AD only) | |
16+
17+## Usage
18+
19+1. Add an application: go to [https://portal.azure.com](https://portal.azure.com), choose **Azure Active Directory**, select
20+ **App registrations** and then click on **New registration**.
21+2. Pick a name, check the supported account type(single-tenant, multi-tenant, etc). In the **Redirect URI** section create a new
22+ **Web** platform entry for each app that you want to protect by the oauth2 proxy(e.g.
23+ https://internal.yourcompanycom/oauth2/callback). Click **Register**.
24+3. Next we need to add group read permissions for the app registration, on the **API Permissions** page of the app, click on
25+ **Add a permission**, select **Microsoft Graph**, then select **Application permissions**, then click on **Group** and select
26+ **Group.Read.All**. Hit **Add permissions** and then on **Grant admin consent** (you might need an admin to do this).
27+ <br/>**IMPORTANT**: Even if this permission is listed with **"Admin consent required=No"** the consent might actually
28+ be required, due to AAD policies you won't be able to see. If you get a **"Need admin approval"** during login,
29+ most likely this is what you're missing!
30+4. Next, if you are planning to use v2.0 Azure Auth endpoint, go to the **Manifest** page and set `"accessTokenAcceptedVersion": 2`
31+ in the App registration manifest file.
32+5. On the **Certificates & secrets** page of the app, add a new client secret and note down the value after hitting **Add**.
33+6. Configure the proxy with:
34+- for V1 Azure Auth endpoint (Azure Active Directory Endpoints - https://login.microsoftonline.com/common/oauth2/authorize)
35+
36+```
37+ --provider=azure
38+ --client-id=<application ID from step 3>
39+ --client-secret=<value from step 5>
40+ --azure-tenant={tenant-id}
41+ --oidc-issuer-url=https://sts.windows.net/{tenant-id}/
42+```
43+
44+- for V2 Azure Auth endpoint (Microsoft Identity Platform Endpoints - https://login.microsoftonline.com/common/oauth2/v2.0/authorize)
45+```
46+ --provider=azure
47+ --client-id=<application ID from step 3>
48+ --client-secret=<value from step 5>
49+ --azure-tenant={tenant-id}
50+ --oidc-issuer-url=https://login.microsoftonline.com/{tenant-id}/v2.0
51+```
52+
53+***Notes***:
54+- When using v2.0 Azure Auth endpoint (`https://login.microsoftonline.com/{tenant-id}/v2.0`) as `--oidc_issuer_url`, in conjunction
55+ with `--resource` flag, be sure to append `/.default` at the end of the resource name. See
56+ https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-permissions-and-consent#the-default-scope for more details.
57+- When using the Azure Auth provider with nginx and the cookie session store you may find the cookie is too large and doesn't
58+ get passed through correctly. Increasing the proxy_buffer_size in nginx or implementing the
59+ [redis session storage](../sessions.md#redis-storage) should resolve this.
docs/docs/configuration/providers/ms_entra_id.mdnew file+201
@@ -0,0 +1,201 @@
1+---
2+id: ms_entra_id
3+title: Microsoft Entra ID
4+---
5+
6+Provider for Microsoft Entra ID. Fully compliant with OIDC, with support for group overage and multi-tenant apps.
7+
8+## Config Options
9+
10+The provider is OIDC-compliant, so all the OIDC parameters are honored. Additional provider-specific configuration parameters are:
11+
12+| Flag | Toml Field | Type | Description | Default |
13+| --------------------------- | -------------------------- | -------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
14+| `--entra-id-allowed-tenant` | `entra_id_allowed_tenants` | string \| list | List of allowed tenants. In case of multi-tenant apps, incoming tokens are issued by different issuers and OIDC issuer verification needs to be disabled. When not specified, all tenants are allowed. Redundant for single-tenant apps (regular ID token validation matches the issuer). | |
15+| `--entra-id-federated-token-auth` | `entra_id_federated_token_auth` | boolean | Enable oAuth2 client authentication with federated token projected by Entra Workload Identity plugin, instead of client secret. | false |
16+
17+## Configure App registration
18+To begin, create an App registration, set a redirect URI, and generate a secret. All account types are supported, including single-tenant, multi-tenant, multi-tenant with Microsoft accounts, and Microsoft accounts only.
19+
20+<details>
21+ <summary>See Azure Portal example</summary>
22+ <div class="videoBlock">
23+ <iframe src="https://www.youtube.com/embed/IUNfxhOzr4E"></iframe>
24+ </div>
25+</details>
26+
27+<details>
28+ <summary>See Terraform example</summary>
29+```
30+ resource "azuread_application" "auth" {
31+ display_name = "oauth2-proxy"
32+ sign_in_audience = "AzureADMyOrg" # Others are also supported
33+
34+ web {
35+ redirect_uris = [
36+ "https://podinfo.lakis.tech/oauth2/callback",
37+ ]
38+ }
39+ // We don't specify any required API permissions - we allow user consent only
40+ }
41+
42+ resource "azuread_service_principal" "sp" {
43+ client_id = azuread_application.auth.client_id
44+ app_role_assignment_required = false
45+ }
46+
47+ resource "azuread_service_principal_password" "pass" {
48+ service_principal_id = azuread_service_principal.sp.id
49+ }
50+
51+```
52+</details>
53+
54+### Configure groups
55+If you want to make use of groups, you can configure *groups claim* to be present in ID Tokens issued by the App registration.
56+<details>
57+ <summary>See Azure Portal example</summary>
58+ <div class="videoBlock">
59+ <div class="videoBlock">
60+ <iframe src="https://www.youtube.com/embed/QZmP5MKEJis"></iframe>
61+ </div>
62+ </div>
63+</details>
64+<details>
65+ <summary>See Terraform example</summary>
66+```
67+ resource "azuread_application" "auth" {
68+ display_name = "oauth2-proxy"
69+ sign_in_audience = "AzureADMyOrg"
70+
71+ group_membership_claims = [
72+ "SecurityGroup"
73+ ]
74+
75+ web {
76+ redirect_uris = [
77+ "https://podinfo.lakis.tech/oauth2/callback",
78+ ]
79+ }
80+ }
81+
82+ resource "azuread_service_principal" "sp" {
83+ client_id = azuread_application.auth.client_id
84+ app_role_assignment_required = false
85+ }
86+
87+ resource "azuread_service_principal_password" "pass" {
88+ service_principal_id = azuread_service_principal.sp.id
89+ }
90+
91+```
92+</details>
93+
94+### Scopes and claims
95+For single-tenant and multi-tenant apps without groups, the only required scope is `openid` (See: [Scopes and permissions](https://learn.microsoft.com/en-us/entra/identity-platform/scopes-oidc#the-openid-scope)).
96+
97+To make use of groups - for example use `allowed_groups` setting or authorize based on groups inside your service - you need to enable *groups claims* in the App Registration. When enabled, list of groups is present in the issued ID token. No additional scopes are required besides `openid`. This works up to 200 groups.
98+
99+When user has more than 200 group memberships, OAuth2-Proxy attempts to retrieve the complete list from Microsoft Graph API's [`transitiveMemberOf`](https://learn.microsoft.com/en-us/graph/api/user-list-transitivememberof). Endpoint requires `User.Read` scope (delegated permission). This permission can be by default consented by user during first login. Set scope to `openid User.Read` to request user consent. Without proper scope, user with 200+ groups will authenticate with 0 groups. See: [group overages](https://learn.microsoft.com/en-us/security/zero-trust/develop/configure-tokens-group-claims-app-roles#group-overages).
100+
101+Alternatively to user consent, both `openid` and `User.Read` permissions can be consented by admistrator. Then, user is not asked for consent on the first login, and group overage works with `openid` scope only. Admin consent can also be required for some tenants. It can be granted with [azuread_service_principal_delegated_permission_grant](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/service_principal_delegated_permission_grant) terraform resource.
102+
103+For personal microsoft accounts, required scope is `openid profile email`.
104+
105+See: [Overview of permissions and consent in the Microsoft identity platform](https://learn.microsoft.com/en-us/entra/identity-platform/permissions-consent-overview).
106+
107+### Multi-tenant apps
108+To authenticate apps from multiple tenants (including personal Microsoft accounts), set the common OIDC issuer url and disable verification:
109+```toml
110+oidc_issuer_url=https://login.microsoftonline.com/common/v2.0
111+insecure_oidc_skip_issuer_verification=true
112+```
113+`insecure_oidc_skip_issuer_verification` setting is required to disable following checks:
114+* Startup check for matching issuer URL returned from [discovery document](https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration) with `oidc_issuer_url` setting. Required, as document's `issuer` field doesn't equal to `https://login.microsoftonline.com/common/v2.0`. See [OIDC Discovery 4.3](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationValidation).
115+* Matching ID token's `issuer` claim with `oidc_issuer_url` setting during ID token validation. Required to support tokens issued by different tenants. See [OIDC Core 3.1.3.7](https://openid.net/specs/openid-connect-core-1_0.html#IDTokenValidation).
116+
117+To provide additional security, Entra ID provider performs check on the ID token's `issuer` claim to match the `https://login.microsoftonline.com/{tenant-id}/v2.0` template.
118+
119+### Workload Identity
120+Provider supports authentication with federated token, without need of using client secret. Following conditions have to be met:
121+
122+* Cluster has public OIDC provider URL. For major cloud providers, it can be enabled with a single flag, for example for [Azure Kubernetes Service deployed with Terraform](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/kubernetes_cluster), it's `oidc_issuer_enabled`.
123+* Workload Identity admission webhook is deployed on the cluster. For AKS, it can be enabled with a flag (`workload_identity_enabled` in Terraform resource), for clusters outside of Azure, it can be installed from [helm chart](https://github.com/Azure/azure-workload-identity).
124+* Appropriate federated credential is added to application registration.
125+<details>
126+ <summary>See federated credential terraform example</summary>
127+```
128+ resource "azuread_application_federated_identity_credential" "fedcred" {
129+ application_id = azuread_application.application.id # ID of your application
130+ display_name = "federation-cred"
131+ description = "Workload identity for oauth2-proxy"
132+ audiences = ["api://AzureADTokenExchange"] # Fixed value
133+ issuer = "https://cluster-oidc-issuer-url..."
134+ subject = "system:serviceaccount:oauth2-proxy-namespace-name:oauth2-proxy-sa-name" # set proper NS and SA name
135+ }
136+```
137+</details>
138+
139+* Kubernetes service account associated with oauth2-proxy deployment, is annotated with `azure.workload.identity/client-id: <app-registration-client-id>`
140+* oauth2-proxy pod is labeled with `azure.workload.identity/use: "true"`
141+* oauth2-proxy is configured with `entra_id_federated_token_auth` set to `true`.
142+
143+`client_secret` setting can be omitted when using federated token authentication.
144+
145+See: [Azure Workload Identity documentation](https://azure.github.io/azure-workload-identity/docs/).
146+
147+### Example configurations
148+Single-tenant app without groups (*groups claim* not enabled). Consider using generic OIDC provider:
149+```toml
150+provider="entra-id"
151+oidc_issuer_url="https://login.microsoftonline.com/<tenant-id>/v2.0"
152+client_id="<client-id>"
153+client_secret="<client-secret>"
154+scope="openid"
155+```
156+
157+Single-tenant app with up to 200 groups (*groups claim* enabled). Consider using generic OIDC provider:
158+```toml
159+provider="entra-id"
160+oidc_issuer_url="https://login.microsoftonline.com/<tenant-id>/v2.0"
161+client_id="<client-id>"
162+client_secret="<client-secret>"
163+scope="openid"
164+allowed_groups=["ac51800c-2679-4ecb-8130-636380a3b491"]
165+```
166+
167+Single-tenant app with more than 200 groups:
168+```toml
169+provider="entra-id"
170+oidc_issuer_url="https://login.microsoftonline.com/<tenant-id>/v2.0"
171+client_id="<client-id>"
172+client_secret="<client-secret>"
173+scope="openid User.Read"
174+allowed_groups=["968b4844-d5e7-4e18-a834-59927959369f"]
175+```
176+
177+Single-tenant app with more than 200 groups and workload identity enabled:
178+```toml
179+provider="entra-id"
180+oidc_issuer_url="https://login.microsoftonline.com/<tenant-id>/v2.0"
181+client_id="<client-id>"
182+scope="openid User.Read"
183+allowed_groups=["968b4844-d5e7-4e18-a834-59927959369f"]
184+entra_id_federated_token_auth=true
185+```
186+
187+Multi-tenant app with Microsoft personal accounts & one Entra tenant allowed, with group overage considered:
188+```toml
189+provider="entra-id"
190+oidc_issuer_url="https://login.microsoftonline.com/common/v2.0"
191+client_id="<client-id>"
192+client_secret="<client-secret>"
193+insecure_oidc_skip_issuer_verification=true
194+scope="openid profile email User.Read"
195+entra_id_allowed_tenants=["9188040d-6c67-4c5b-b112-36a304b66dad","<my-tenant-id>"] # Allow only <my-tenant-id> and Personal MS Accounts tenant
196+email_domains="*"
197+```
198+
199+## Kubernetes Dashboard Integration
200+
201+For a complete guide on integrating oauth2-proxy with Kubernetes Dashboard on AKS using Azure Entra ID authentication, including detailed configuration examples, RBAC setup, troubleshooting, and Workload Identity setup, see the [Kubernetes Dashboard integration guide](../integrations/kubernetes-dashboard.md).
docs/docs/configuration/providers/sourcehut.mdnew file+25
@@ -0,0 +1,25 @@
1+---
2+id: sourcehut
3+title: SourceHut
4+---
5+
6+1. Create a new OAuth client: https://meta.sr.ht/oauth2
7+2. Under `Redirection URI` enter the correct URL, i.e.
8+ `https://internal.yourcompany.com/oauth2/callback`
9+
10+To use the provider, start with `--provider=sourcehut`.
11+
12+If you are hosting your own SourceHut instance, make sure you set the following
13+to the appropriate URLs:
14+
15+```shell
16+ --login-url="https://<meta.your.instance>/oauth2/authorize"
17+ --redeem-url="https://<meta.your.instance>/oauth2/access-token"
18+ --profile-url="https://<meta.your.instance>/query"
19+ --validate-url="https://<meta.your.instance>/profile"
20+```
21+
22+The default configuration allows everyone with an account to authenticate.
23+Restricting access is currently only supported by
24+[email](index.md#email-authentication).
25+
docs/docs/configuration/sessions.md+6−4
@@ -60,13 +60,15 @@ Two settings are used to configure the OAuth2 Proxy cookie lifetime:
6060
6161The "cookie-expire" value should be equal to the lifetime of the Refresh-Token that is issued by the OAuth2 authorization server.
6262If it expires earlier and is deleted by the browser, OAuth2 Proxy cannot find the stored Refresh-Tokens in Redis and thus cannot start
63−the refresh flow to get new Access-Tokens. If it is longer, it might be that the old Refresh-Token will be found in Redis but has already
63+the refresh flow to get a new Access-Token. If it is longer, it might be that the old Refresh-Token will be found in Redis but has already
6464expired.
6565
6666The "cookie-refresh" value controls when OAuth2 Proxy tries to refresh an Access-Token. If it is set to "0", the
67−Access-Token will never be refreshed, even it is already expired and there would be a valid Refresh-Token in the
68−available. If set, OAuth2 Proxy will refresh the Access-Token after this many seconds even if it is still valid.
69−Of course, it will also be refreshed after it has expired, as long as a Refresh Token is available.
67+Access-Token will never be refreshed, even if it is already expired and a valid Refresh-Token is available. If set, OAuth2 Proxy will
68+refresh the Access-Token after this many seconds whether it is still valid or not. According to the official OAuth2.0 specification
69+Access-Tokens are not required to follow a specific format. Therefore OAuth2 Proxy cannot check for any expiry date without an
70+introspection endpoint. If an Access-Token expires and you have not set a corresponding "cookie-refresh" value, you will likely
71+encounter expiry issues.
7072
7173Caveat: It can happen that the Access-Token is valid for e.g. "1m" and a request happens after exactly "59s".
7274It would pass OAuth2 Proxy and be forwarded to the backend but is just expired when the backend tries to validate
docs/docs/configuration/systemd_socket.mdnew file+51
@@ -0,0 +1,51 @@
1+---
2+id: systemd_socket
3+title: Systemd Socket Activation
4+---
5+
6+Pass an existing listener created by systemd.socket to oauth2-proxy.
7+
8+To do this create a socket:
9+
10+oauth2-proxy.socket
11+```
12+[Socket]
13+ListenStream=%t/oauth2.sock
14+SocketGroup=www-data
15+SocketMode=0660
16+```
17+
18+Now it's possible to call this socket from e.g. nginx:
19+```
20+server {
21+ location /oauth2/ {
22+ proxy_pass http://unix:/run/oauth2-proxy/oauth2.sock;
23+}
24+```
25+
26+The oauth2-proxy should have `--http-address=fd:3` as a parameter.
27+Here fd is case insensitive and means file descriptor. The number 3 refers to the first non-stdin/stdout/stderr file descriptor,
28+systemd-socket-activate (which is what systemd.socket uses), listens to what it is told and passes
29+the listener it created onto the process, starting with file descriptor 3.
30+
31+```
32+./oauth2-proxy \
33+ --http-address="fd:3" \
34+ --email-domain="yourcompany.com" \
35+ --upstream=http://127.0.0.1:8080/ \
36+ --cookie-secret=... \
37+ --cookie-secure=true \
38+ --provider=... \
39+ --client-id=... \
40+ --client-secret=...
41+```
42+
43+## Trusted IPs
44+
45+When listening on a Unix socket, Go sets `http.Request.RemoteAddr` to `"@"` instead of the usual `"host:port"` format. This means there is no client IP available from the connection itself.
46+
47+As a result, `--trusted-ip` entries cannot match against the direct connection address for Unix socket listeners. Requests arriving over a Unix socket will never be considered "trusted" based on their `RemoteAddr`. IP-based trust decisions will still work if a trusted reverse proxy sets `X-Forwarded-For` or `X-Real-IP` headers and `--reverse-proxy=true` is configured.
48+
49+## TLS
50+
51+Currently TLS is not supported (but it's doable).
docs/docs/features/endpoints.md+27−1
@@ -5,6 +5,7 @@ title: Endpoints
55
66OAuth2 Proxy responds directly to the following endpoints. All other endpoints will be proxied upstream when authenticated. The `/oauth2` prefix can be changed with the `--proxy-prefix` config variable.
77
8+- / - the proxy endpoint provides authentication and returns the appropriate 40x error if not authenticated or authorized then passes the request upstream.
89- /robots.txt - returns a 200 OK response that disallows all User-agents from all paths; see [robotstxt.org](http://www.robotstxt.org/) for more info
910- /ping - returns a 200 OK response, which is intended for use with health checks
1011- /ready - returns a 200 OK response if all the underlying connections (e.g., Redis store) are connected
@@ -14,7 +15,7 @@ OAuth2 Proxy responds directly to the following endpoints. All other endpoints w
1415- /oauth2/start - a URL that will redirect to start the OAuth cycle
1516- /oauth2/callback - the URL used at the end of the OAuth cycle. The oauth app will be configured with this as the callback url.
1617- /oauth2/userinfo - the URL is used to return user's email from the session in JSON format.
17−- /oauth2/auth - only returns a 202 Accepted response or a 401 Unauthorized response; for use with the [Nginx `auth_request` directive](../configuration/overview.md#configuring-for-use-with-the-nginx-auth_request-directive)
18+- /oauth2/auth - only returns a 202 Accepted response or a 401 Unauthorized response; for use with the [Nginx `auth_request` directive](../configuration/integrations/nginx)
1819- /oauth2/static/\* - stylesheets and other dependencies used in the sign_in and error pages
1920
2021### Sign out
@@ -37,6 +38,20 @@ X-Auth-Request-Redirect: https://my-oidc-provider/sign_out_page
3738
3839BEWARE that the domain you want to redirect to (`my-oidc-provider.example.com` in the example) must be added to the [`--whitelist-domain`](../configuration/overview) configuration option otherwise the redirect will be ignored. Make sure to include the actual domain and port (if needed) and not the URL (e.g "localhost:8081" instead of "http://localhost:8081").
3940
41+ID Token can be injected in the redirect url by using `{id_token}` placeholder. For example to redirect to `https://my-oidc-provider.example.com/sign_out_page?id_token_hint={id_token}&post_logout_redirect_uri=https://my-app.example.com`;
42+
43+```
44+/oauth2/sign_out?rd=https%3A%2F%2Fmy-oidc-provider.example.com%2Fsign_out_page%3Fid_token_hint%3D%7Bid_token%7D%26post_logout_redirect_uri%3Dhttps%3A%2F%2Fmy-app.example.com
45+```
46+
47+or alternatively in the header:
48+
49+```
50+GET /oauth2/sign_out HTTP/1.1
51+X-Auth-Request-Redirect: https://my-oidc-provider.example.com/sign_out_page?id_token_hint={id_token}&post_logout_redirect_uri=https://my-app.example.com
52+...
53+```
54+
4055### Auth
4156
4257This endpoint returns 202 Accepted response or a 401 Unauthorized response.
@@ -45,3 +60,14 @@ It can be configured using the following query parameters:
4560- `allowed_groups`: comma separated list of allowed groups
4661- `allowed_email_domains`: comma separated list of allowed email domains
4762- `allowed_emails`: comma separated list of allowed emails
63+
64+### Proxy (/)
65+
66+This endpoint returns the upstream response if authenticated.
67+If unauthenticated it returns a 401 Unauthorized. If the authenticatd user
68+is not in one of the allowed groups, or emails then it returns a 403 forbidden
69+
70+It can be configured using the following query parameters:
71+- `allowed_groups`: comma separated list of allowed groups
72+- `allowed_email_domains`: comma separated list of allowed email domains
73+- `allowed_emails`: comma separated list of allowed emails
docs/docs/installation.md+3−2
@@ -5,7 +5,7 @@ title: Installation
55
661. Choose how to deploy:
77
8− a. Using a [Prebuilt Binary](https://github.com/oauth2-proxy/oauth2-proxy/releases) (current release is `v7.6.0`)
8+ a. Using a [Prebuilt Binary](https://github.com/oauth2-proxy/oauth2-proxy/releases) (current release is `v7.15.4`)
99
1010 b. Using Go to install the latest release
1111 ```bash
@@ -13,7 +13,7 @@ title: Installation
1313 ```
1414 This will install the binary into `$GOPATH/bin`. Make sure you include `$GOPATH` in your `$PATH`. Otherwise your system won't find binaries installed via `go install`
1515
16− c. Using a [Prebuilt Docker Image](https://quay.io/oauth2-proxy/oauth2-proxy) (AMD64, PPC64LE, ARMv6, ARMv7, and ARM64 available)
16+ c. Using a [Prebuilt Docker Image](https://quay.io/oauth2-proxy/oauth2-proxy) (AMD64, PPC64LE, S390x, ARMv6, ARMv7, and ARM64 available)
1717
1818 d. Using a [Pre-Release Nightly Docker Image](https://quay.io/oauth2-proxy/oauth2-proxy-nightly) (AMD64, PPC64LE, ARMv6, ARMv7, and ARM64 available)
1919
@@ -29,3 +29,4 @@ title: Installation
29292. [Select a Provider and Register an OAuth Application with a Provider](configuration/providers/index.md)
30303. [Configure OAuth2 Proxy using config file, command line options, or environment variables](configuration/overview.md)
31314. [Configure SSL or Deploy behind an SSL endpoint](configuration/tls.md) (example provided for Nginx)
32+5. [Configure OAuth2 Proxy using systemd.socket](configuration/systemd_socket.md) (example provided for Nginx/Systemd)
docs/docs/welcome.md+11−1
@@ -20,4 +20,14 @@ A list of changes can be seen in the [CHANGELOG](https://github.com/oauth2-proxy
2020
2121## Architecture
2222
23−![OAuth2 Proxy Architecture](/img/architecture.svg)
23+![OAuth2 Proxy Architecture](/img/simplified-architecture.svg)
24+
25+
26+## Cloud Native Computing Foundation
27+
28+OAuth2 Proxy is a [Cloud Native Computing Foundation](https://cncf.io) Sandbox project.
29+
30+![CNCF](https://www.cncf.io/wp-content/uploads/2023/04/cncf-main-site-logo.svg)
31+
32+The Linux Foundation® (TLF) has registered trademarks and uses trademarks. For a list of TLF trademarks, see [Trademark Usage](https://www.linuxfoundation.org/legal/trademark-usage).
33+
docs/docusaurus.config.js+3−3
@@ -105,7 +105,7 @@ const config = {
105105 dropdownActiveClassDisabled: true,
106106 },
107107 {
108− href: 'https://gophers.slack.com/messages/CM2RSS25N',
108+ href: 'https://cloud-native.slack.com/archives/C098Y5URZ2N',
109109 label: 'Slack',
110110 position: 'right',
111111 },
@@ -118,12 +118,12 @@ const config = {
118118 },
119119 footer: {
120120 style: 'dark',
121− copyright: `Copyright © ${new Date().getFullYear()} OAuth2 Proxy.`,
121+ copyright: `Copyright © ${new Date().getFullYear()} OAuth2 Proxy a Series of LF Projects, LLC.<br>For website terms of use, trademark policy and other project policies please see lfprojects.org/policies/`,
122122 },
123123 prism: {
124124 theme: prismThemes.github,
125125 darkTheme: prismThemes.dracula,
126− additionalLanguages: ['hcl', 'powershell'],
126+ additionalLanguages: ['hcl', 'nginx', 'powershell'],
127127 },
128128 }),
129129};
docs/package-lock.jsondeleted−15901

This diff is too big to show here.

docs/package.json+4−1

This diff is too big to show here.

docs/sidebars.js+36−16

This diff is too big to show here.

docs/src/css/custom.css+14

This diff is too big to show here.

docs/static/img/architecture.svgdeleted−1

This diff is too big to show here.

docs/static/img/simplified-architecture.svgnew file+4

This diff is too big to show here.

docs/versioned_docs/version-7.0.x/behaviour.md+1−1

This diff is too big to show here.

docs/versioned_docs/version-7.0.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.1.x/behaviour.md+1−1

This diff is too big to show here.

docs/versioned_docs/version-7.1.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/community/contribution.mdnew file+89

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/alpha_config.mdnew file+564

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/integration.mdnew file+386

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/overview.mdnew file+403

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/google.mdnew file+76

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/index.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.10.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/community/contribution.mdnew file+89

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/alpha_config.mdnew file+564

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/integration.mdnew file+386

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/overview.mdnew file+406

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/google.mdnew file+75

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/index.mdnew file+44

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/providers/sourcehut.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.11.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/community/contribution.mdnew file+89

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/alpha_config.mdnew file+565

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/integration.mdnew file+386

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/overview.mdnew file+407

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/cidaas.mdnew file+37

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/google.mdnew file+75

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/index.mdnew file+45

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/providers/sourcehut.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.12.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/community/contribution.mdnew file+91

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/alpha_config.mdnew file+568

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/caddy.mdnew file+63

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/headlamp.mdnew file+105

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/index.mdnew file+41

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/kubernetes-dashboard.mdnew file+289

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/nginx.mdnew file+174

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/integrations/traefik.mdnew file+192

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/overview.mdnew file+407

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/cidaas.mdnew file+37

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/cisco_duo.mdnew file+44

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/google.mdnew file+84

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/index.mdnew file+46

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/providers/sourcehut.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.13.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/community/contribution.mdnew file+91

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/alpha_config.mdnew file+637

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/alpha_config.md.tmplnew file+218

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/caddy.mdnew file+63

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/headlamp.mdnew file+105

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/index.mdnew file+41

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/kubernetes-dashboard.mdnew file+289

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/nginx.mdnew file+174

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/integrations/traefik.mdnew file+192

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/overview.mdnew file+407

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/cidaas.mdnew file+37

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/cisco_duo.mdnew file+44

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/google.mdnew file+84

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/index.mdnew file+46

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/providers/sourcehut.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/features/endpoints.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.14.x/welcome.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/community/contribution.mdnew file+91

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/alpha_config.mdnew file+702

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/alpha_config.md.tmplnew file+281

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/caddy.mdnew file+63

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/headlamp.mdnew file+105

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/index.mdnew file+41

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/kubernetes-dashboard.mdnew file+289

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/nginx.mdnew file+174

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/integrations/traefik.mdnew file+192

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/overview.mdnew file+451

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/cidaas.mdnew file+37

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/cisco_duo.mdnew file+44

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/github.mdnew file+81

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/google.mdnew file+84

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/index.mdnew file+46

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/ms_entra_id.mdnew file+201

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/providers/sourcehut.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/systemd_socket.mdnew file+51

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/features/endpoints.mdnew file+73

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.15.x/welcome.mdnew file+33

This diff is too big to show here.

docs/versioned_docs/version-7.2.x/behaviour.md+20−5

This diff is too big to show here.

docs/versioned_docs/version-7.2.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.3.x/behaviour.md+20−5

This diff is too big to show here.

docs/versioned_docs/version-7.3.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.4.x/behaviour.md+20−5

This diff is too big to show here.

docs/versioned_docs/version-7.4.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.5.x/behaviour.md+20−5

This diff is too big to show here.

docs/versioned_docs/version-7.5.x/configuration/overview.md+2−2

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/behaviour.md+20−5

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/integration.mdnew file+318

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/overview.md+247−464

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/providers/github.md+12

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/providers/gitlab.md+10−1

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/providers/google.md+14−1

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/configuration/providers/keycloak_oidc.md+8

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/features/endpoints.md+1−1

This diff is too big to show here.

docs/versioned_docs/version-7.6.x/welcome.md+1−1

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/community/contribution.mdnew file+78

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/alpha_config.mdnew file+546

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/integration.mdnew file+318

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/overview.mdnew file+396

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/docs/configuration/providers/azure.md → docs/versioned_docs/version-7.7.x/configuration/providers/azure.mdrenamed+9

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/azure_ad.mdnew file+18

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/gitea.mdnew file+20

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/github.mdnew file+67

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/google.mdnew file+76

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/index.mdnew file+42

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/installation.mdnew file+31

This diff is too big to show here.

docs/versioned_docs/version-7.7.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/community/contribution.mdnew file+89

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/alpha_config.mdnew file+563

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/integration.mdnew file+318

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/overview.mdnew file+401

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/github.mdnew file+67

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/google.mdnew file+76

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/index.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.8.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/behaviour.mdnew file+26

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/community/contribution.mdnew file+89

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/community/security.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/alpha_config.mdnew file+564

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/alpha_config.md.tmplnew file+139

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/integration.mdnew file+318

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/overview.mdnew file+403

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/adfs.mdnew file+19

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/bitbucket.mdnew file+25

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/digitalocean.mdnew file+21

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/facebook.mdnew file+7

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/gitea.mdnew file+24

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/github.mdnew file+67

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/gitlab.mdnew file+49

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/google.mdnew file+76

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/index.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/keycloak.mdnew file+36

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/keycloak_oidc.mdnew file+151

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/linkedin.mdnew file+13

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/login_gov.mdnew file+79

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/ms_azure_ad.mdnew file+59

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/ms_entra_id.mdnew file+197

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/nextcloud.mdnew file+28

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/providers/openid_connect.mdnew file+146

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/sessions.mdnew file+99

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/systemd_socket.mdnew file+43

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/configuration/tls.mdnew file+85

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/features/endpoints.mdnew file+47

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/installation.mdnew file+32

This diff is too big to show here.

docs/versioned_docs/version-7.9.x/welcome.mdnew file+23

This diff is too big to show here.

docs/versioned_sidebars/version-7.10.x-sidebars.jsonnew file+83

This diff is too big to show here.

docs/versioned_sidebars/version-7.11.x-sidebars.jsonnew file+84

This diff is too big to show here.

docs/versioned_sidebars/version-7.12.x-sidebars.jsonnew file+84

This diff is too big to show here.

docs/versioned_sidebars/version-7.13.x-sidebars.jsonnew file+100

This diff is too big to show here.

docs/versioned_sidebars/version-7.14.x-sidebars.jsonnew file+100

This diff is too big to show here.

docs/versioned_sidebars/version-7.15.x-sidebars.jsonnew file+100

This diff is too big to show here.

docs/versioned_sidebars/version-7.6.x-sidebars.json+1

This diff is too big to show here.

docs/versioned_sidebars/version-7.7.x-sidebars.jsonnew file+83

This diff is too big to show here.

docs/versioned_sidebars/version-7.8.x-sidebars.jsonnew file+83

This diff is too big to show here.

docs/versioned_sidebars/version-7.9.x-sidebars.jsonnew file+83

This diff is too big to show here.

docs/versions.json+9

This diff is too big to show here.

go.mod+61−75

This diff is too big to show here.

go.sum+166−306

This diff is too big to show here.

main.go+45−14

This diff is too big to show here.

main_suite_test.go+1−1

This diff is too big to show here.

main_test.go+162−56

This diff is too big to show here.

oauthproxy.go+113−43

This diff is too big to show here.

oauthproxy_test.go+423−79

This diff is too big to show here.

pkg/apis/middleware/middleware_suite_test.go+1−1

This diff is too big to show here.

pkg/apis/middleware/scope.go+48−1

This diff is too big to show here.

pkg/apis/middleware/scope_test.go+35−1

This diff is too big to show here.

pkg/apis/middleware/session.go+5−1

This diff is too big to show here.

pkg/apis/options/alpha_options.go+25−16

This diff is too big to show here.

pkg/apis/options/common.godeleted−63

This diff is too big to show here.

pkg/apis/options/common_test.godeleted−88

This diff is too big to show here.

pkg/apis/options/cookie.go+49−22

This diff is too big to show here.

pkg/apis/options/cookie_test.gonew file+70

This diff is too big to show here.

pkg/apis/options/doc.go+2−1

This diff is too big to show here.

pkg/apis/options/header.go+54−9

This diff is too big to show here.

pkg/apis/options/hooks.gonew file+57

This diff is too big to show here.

pkg/apis/options/hooks_test.gonew file+96

This diff is too big to show here.

pkg/apis/options/legacy_options.go+90−45

This diff is too big to show here.

pkg/apis/options/legacy_options_test.go+124−77

This diff is too big to show here.

pkg/apis/options/load.go+92−36

This diff is too big to show here.

pkg/apis/options/load_test.go+50−23

This diff is too big to show here.

pkg/apis/options/login_url_parameters.go+5−5

This diff is too big to show here.

pkg/apis/options/options.go+48−23

This diff is too big to show here.

pkg/apis/options/options_suite_test.go+1−1

This diff is too big to show here.

pkg/apis/options/providers.go+233−67

This diff is too big to show here.

pkg/apis/options/secret_source.gonew file+19

This diff is too big to show here.

pkg/apis/options/server.go+16−7

This diff is too big to show here.

pkg/apis/options/testutil/options_matcher_test.go+1−1

This diff is too big to show here.

pkg/apis/options/upstreams.go+110−23

This diff is too big to show here.

pkg/apis/options/util/util_suite_test.go+1−1

This diff is too big to show here.

pkg/apis/options/util/util_test.go+1−1

This diff is too big to show here.

pkg/apis/sessions/session_state.go+30−7

This diff is too big to show here.

pkg/apis/sessions/session_state_test.go+105−15

This diff is too big to show here.

pkg/app/pagewriter/error_page_test.go+1−1

This diff is too big to show here.

pkg/app/pagewriter/pagewriter_suite_test.go+1−1

This diff is too big to show here.

pkg/app/pagewriter/pagewriter_test.go+4−5

This diff is too big to show here.

pkg/app/pagewriter/sign_in_page_test.go+1−2

This diff is too big to show here.

pkg/app/pagewriter/static_pages_test.go+1−1

This diff is too big to show here.

pkg/app/pagewriter/templates_test.go+1−1

This diff is too big to show here.

pkg/app/redirect/director_test.go+45−14

This diff is too big to show here.

pkg/app/redirect/pagewriter_suite_test.go+1−1

This diff is too big to show here.

pkg/app/redirect/validator_test.go+1−2

This diff is too big to show here.

pkg/authentication/basic/basic_suite_test.go+1−1

This diff is too big to show here.

pkg/authentication/basic/htpasswd.go+1−1

This diff is too big to show here.

pkg/authentication/basic/htpasswd_test.go+12−10

This diff is too big to show here.

pkg/authentication/hmacauth/LICENSE.mdnew file+5

This diff is too big to show here.

pkg/authentication/hmacauth/hmacauth.gonew file+237

This diff is too big to show here.

pkg/authentication/hmacauth/hmacauth_test.gonew file+302

This diff is too big to show here.

pkg/clock/clock.godeleted−157

This diff is too big to show here.

pkg/clock/clock_suite_test.godeleted−17

This diff is too big to show here.

pkg/clock/clock_test.godeleted−380

This diff is too big to show here.

pkg/cookies/cookies.go+19−7

This diff is too big to show here.

pkg/cookies/cookies_suite_test.go+5−8

This diff is too big to show here.

pkg/cookies/cookies_test.go+49−43

This diff is too big to show here.

pkg/cookies/csrf.go+123−43

This diff is too big to show here.

pkg/cookies/csrf_per_request_test.go+90−7

This diff is too big to show here.

pkg/cookies/csrf_test.go+354−9

This diff is too big to show here.

pkg/encryption/cipher.go+2−2

This diff is too big to show here.

pkg/encryption/nonce.go+8−9

This diff is too big to show here.

pkg/encryption/utils.go+7−11

This diff is too big to show here.

pkg/encryption/utils_test.go+4−4

This diff is too big to show here.

pkg/header/header_suite_test.go+1−1

This diff is too big to show here.

pkg/header/injector_test.go+1−2

This diff is too big to show here.

pkg/ip/parse_ip_net.go+16

This diff is too big to show here.

pkg/ip/parse_ip_net_test.gonew file+118

This diff is too big to show here.

pkg/ip/realclientip.go+13−2

This diff is too big to show here.

pkg/ip/realclientip_test.go+6

This diff is too big to show here.

pkg/middleware/basic_session_test.go+1−2

This diff is too big to show here.

pkg/middleware/headers.go+40−5

This diff is too big to show here.

pkg/middleware/headers_test.go+50−6

This diff is too big to show here.

pkg/middleware/healthcheck.go+7−4

This diff is too big to show here.

pkg/middleware/healthcheck_test.go+32−11

This diff is too big to show here.

pkg/middleware/jwt_session.go+14−7

This diff is too big to show here.

pkg/middleware/jwt_session_test.go+89−5

This diff is too big to show here.

pkg/middleware/metrics_test.go+1−2

This diff is too big to show here.

pkg/middleware/middleware_suite_test.go+1−1

This diff is too big to show here.

pkg/middleware/readynesscheck_test.go+1−2

This diff is too big to show here.

pkg/middleware/redirect_to_https_test.go+16−2

This diff is too big to show here.

pkg/middleware/request_logger_test.go+1−2

This diff is too big to show here.

pkg/middleware/scope.go+5−3

This diff is too big to show here.

pkg/middleware/scope_test.go+19−5

This diff is too big to show here.

pkg/middleware/session_utils_test.go+1−2

This diff is too big to show here.

pkg/middleware/stored_session.go+47−3

This diff is too big to show here.

pkg/middleware/stored_session_test.go+67−12

This diff is too big to show here.

pkg/providers/oidc/oidc_suite_test.go+1−1

This diff is too big to show here.

pkg/providers/oidc/provider_test.go+1−2

This diff is too big to show here.

pkg/providers/oidc/provider_verifier.go+116−11

This diff is too big to show here.

pkg/providers/oidc/provider_verifier_test.go+156−4

This diff is too big to show here.

pkg/providers/oidc/verifier_test.go+1−1

This diff is too big to show here.

pkg/providers/util/claim_extractor.go+31−82

This diff is too big to show here.

pkg/providers/util/claim_extractor_test.go+65−51

This diff is too big to show here.

pkg/providers/util/util_suite_test.go+1−1

This diff is too big to show here.

pkg/http/http_suite_test.go → pkg/proxyhttp/http_suite_test.gorenamed+2−2

This diff is too big to show here.

pkg/http/server.go → pkg/proxyhttp/server.gorenamed+76−5

This diff is too big to show here.

pkg/http/server_group.go → pkg/proxyhttp/server_group.gorenamed+1−1

This diff is too big to show here.

pkg/http/server_group_test.go → pkg/proxyhttp/server_group_test.gorenamed+2−2

This diff is too big to show here.

pkg/http/server_test.go → pkg/proxyhttp/server_test.gorenamed+373−4

This diff is too big to show here.

pkg/proxyhttp/systemd_socket.gonew file+55

This diff is too big to show here.

pkg/proxyhttp/systemd_unsupported.gonew file+17

This diff is too big to show here.

pkg/requests/builder_test.go+16−16

This diff is too big to show here.

pkg/requests/http.go+3−1

This diff is too big to show here.

pkg/requests/requests_suite_test.go+1−1

This diff is too big to show here.

pkg/requests/result_test.go+3−4

This diff is too big to show here.

pkg/requests/util/util.go+45−11

This diff is too big to show here.

pkg/requests/util/util_suite_test.go+1−1

This diff is too big to show here.

pkg/requests/util/util_test.go+120−23

This diff is too big to show here.

pkg/sessions/cookie/session_store.go+41−22

This diff is too big to show here.

pkg/sessions/cookie/session_store_test.go+1−1

This diff is too big to show here.

pkg/sessions/persistence/manager_test.go+1−1

This diff is too big to show here.

pkg/sessions/persistence/persistence_suite_test.go+1−1

This diff is too big to show here.

pkg/sessions/persistence/ticket.go+36−20

This diff is too big to show here.

pkg/sessions/persistence/ticket_test.go+1−2

This diff is too big to show here.

pkg/sessions/redis/client_test.go+1−1

This diff is too big to show here.

pkg/sessions/redis/redis_store.go+23−9

This diff is too big to show here.

pkg/sessions/redis/redis_store_test.go+177−323

This diff is too big to show here.

pkg/sessions/redis/redis_store_tls_test.gonew file+169

This diff is too big to show here.

pkg/sessions/redis/redis_test.go+35−2

This diff is too big to show here.

pkg/sessions/session_store_test.go+1−1

This diff is too big to show here.

pkg/sessions/tests/session_store_tests.go+49−2

This diff is too big to show here.

pkg/upstream/file.go+39−5

This diff is too big to show here.

pkg/upstream/file_test.go+8−3

This diff is too big to show here.

pkg/upstream/http.go+79−26

This diff is too big to show here.

pkg/upstream/http_test.go+142−35

This diff is too big to show here.

pkg/upstream/proxy.go+19−18

This diff is too big to show here.

pkg/upstream/proxy_test.go+60−11

This diff is too big to show here.

pkg/upstream/rewrite.go+1

This diff is too big to show here.

pkg/upstream/rewrite_test.go+9−2

This diff is too big to show here.

pkg/upstream/static.go+3−11

This diff is too big to show here.

pkg/upstream/static_test.go+1−2

This diff is too big to show here.

pkg/upstream/upstream_suite_test.go+4−2

This diff is too big to show here.

pkg/util/ptr/ptr.gonew file+14

This diff is too big to show here.

pkg/util/ptr/ptr_test.gonew file+38

This diff is too big to show here.

pkg/util/util.go+64

This diff is too big to show here.

pkg/util/util_test.go+70

This diff is too big to show here.

pkg/validation/allowlist.go+14−1

This diff is too big to show here.

pkg/validation/allowlist_test.go+31−2

This diff is too big to show here.

pkg/validation/common_test.go+1−2

This diff is too big to show here.

pkg/validation/cookie.go+23−4

This diff is too big to show here.

pkg/validation/cookie_test.go+48−1

This diff is too big to show here.

pkg/validation/header.go+1

This diff is too big to show here.

pkg/validation/header_test.go+1−2

This diff is too big to show here.

pkg/validation/options.go+7−9

This diff is too big to show here.

pkg/validation/options_test.go+25−4

This diff is too big to show here.

pkg/validation/providers.go+95−17

This diff is too big to show here.

pkg/validation/providers_test.go+54−2

This diff is too big to show here.

pkg/validation/sessions_test.go+6−5

This diff is too big to show here.

pkg/validation/upstreams.go+10−8

This diff is too big to show here.

pkg/validation/upstreams_test.go+27−10

This diff is too big to show here.

pkg/validation/validation_suite_test.go+1−1

This diff is too big to show here.

providers/adfs.go+2−1

This diff is too big to show here.

providers/adfs_test.gomode 100755 → 100644+3−3

This diff is too big to show here.

providers/atlassian-cloud.gonew file+99

This diff is too big to show here.

providers/atlassian-cloud_test.gonew file+93

This diff is too big to show here.

providers/azure.go+4−4

This diff is too big to show here.

providers/cidaas.gonew file+144

This diff is too big to show here.

providers/cidaas_test.gonew file+493

This diff is too big to show here.

providers/dtt_sso.gonew file+202

This diff is too big to show here.

providers/dtt_sso_test.gonew file+237

This diff is too big to show here.

providers/github.go+75−21

This diff is too big to show here.

providers/github_test.go+129

This diff is too big to show here.

providers/gitlab_test.go+1−2

This diff is too big to show here.

providers/google.go+207−40

This diff is too big to show here.

providers/google_test.go+129−12

This diff is too big to show here.

providers/internal_util.go+2−1

This diff is too big to show here.

providers/internal_util_test.go+6

This diff is too big to show here.

providers/keycloak_oidc.go+20−12

This diff is too big to show here.

providers/keycloak_oidc_test.go+31−18

This diff is too big to show here.

providers/keycloak_test.go+1−2

This diff is too big to show here.

providers/logingov.go+4−3

This diff is too big to show here.

providers/ms_entra_id.gonew file+326

This diff is too big to show here.

providers/ms_entra_id_test.gonew file+186

This diff is too big to show here.

providers/oidc.go+29−10

This diff is too big to show here.

providers/oidc_test.go+30−1

This diff is too big to show here.

providers/provider_data.go+46−5

This diff is too big to show here.

providers/provider_data_test.go+23

This diff is too big to show here.

providers/provider_default.go+8−1

This diff is too big to show here.

providers/provider_default_test.go+42−2

This diff is too big to show here.

providers/providers.go+28−11

This diff is too big to show here.

providers/providers_suite_test.go+1−1

This diff is too big to show here.

providers/providers_test.go+138−6

This diff is too big to show here.

providers/srht.gonew file+109

This diff is too big to show here.

providers/srht_test.gonew file+77

This diff is too big to show here.

providers/util_test.go+33

This diff is too big to show here.

tools/tools.godeleted−7

This diff is too big to show here.

validator.go+4−1

This diff is too big to show here.

validator_test.go+21

This diff is too big to show here.