git.iko.soy/typeable/oauth2-proxy
on master help sign in
set providerDefaults for oidc consistently (#1828)
ece3d62Centzilius
CHANGELOG.md+2−1
@@ -18,7 +18,8 @@
18N/A
18N/A
19
19
20## Changes since v7.3.0
20## Changes since v7.3.0
21−
21+- [#1828](https://github.com/oauth2-proxy/oauth2-proxy/pull/1828) call providerData.setProviderDefaults for oidc provider to achieve consistent behaviour (@centzilius)
22+ - UserClaim will be set to sub instead of beeing empty from now on.
22- [#1691](https://github.com/oauth2-proxy/oauth2-proxy/pull/1691) Fix Redis IdleTimeout when Redis timeout option is set to non-zero (@dimss)
23- [#1691](https://github.com/oauth2-proxy/oauth2-proxy/pull/1691) Fix Redis IdleTimeout when Redis timeout option is set to non-zero (@dimss)
23- [#1669](https://github.com/oauth2-proxy/oauth2-proxy/pull/1699) Fix method deprecated error in lint (@t-katsumura)
24- [#1669](https://github.com/oauth2-proxy/oauth2-proxy/pull/1699) Fix method deprecated error in lint (@t-katsumura)
24- [#1701](https://github.com/oauth2-proxy/oauth2-proxy/pull/1701) Watch the htpasswd file for changes and update the htpasswdMap (@aiciobanu)
25- [#1701](https://github.com/oauth2-proxy/oauth2-proxy/pull/1701) Watch the htpasswd file for changes and update the htpasswdMap (@aiciobanu)
providers/oidc.go+8−1
@@ -22,7 +22,14 @@ type OIDCProvider struct {
22
22
23// NewOIDCProvider initiates a new OIDCProvider
23// NewOIDCProvider initiates a new OIDCProvider
24func NewOIDCProvider(p *ProviderData, opts options.OIDCOptions) *OIDCProvider {
24func NewOIDCProvider(p *ProviderData, opts options.OIDCOptions) *OIDCProvider {
25+ p.setProviderDefaults(providerDefaults{
25− p.ProviderName = "OpenID Connect"
26+ name: "OpenID Connect",
27+ loginURL: nil,
28+ redeemURL: nil,
29+ profileURL: nil,
30+ validateURL: nil,
31+ scope: "",
32+ })
26 p.getAuthorizationHeaderFunc = makeOIDCHeader
33 p.getAuthorizationHeaderFunc = makeOIDCHeader
27
34
28 return &OIDCProvider{
35 return &OIDCProvider{