Skip to content

Commit

Permalink
Adjust provider sorting, fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Teko012 committed Aug 21, 2024
1 parent 03da9f5 commit d660000
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
- [#2674](https://github.com/oauth2-proxy/oauth2-proxy/pull/2674) docs: additional notes about available claims for HeaderValue (@vegetablest)
- [#2459](https://github.com/oauth2-proxy/oauth2-proxy/pull/2459) chore(deps): Updated to ginkgo v2 (@kvanzuijlen, @tuunit)
- [#2112](https://github.com/oauth2-proxy/oauth2-proxy/pull/2112) docs: update list of providers which support refresh tokens (@mikefab-msf)
- [#2273](https://github.com/oauth2-proxy/oauth2-proxy/pull/2273) Add Cidaas provider (@Bibob7)
- [#2273](https://github.com/oauth2-proxy/oauth2-proxy/pull/2273) Add Cidaas provider (@Bibob7, @Teko012)

# V7.6.0

Expand Down
6 changes: 3 additions & 3 deletions pkg/apis/options/providers.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,9 @@ const (
// BitbucketProvider is the provider type for Bitbucket
BitbucketProvider ProviderType = "bitbucket"

// CidaasProvider is the provider type for Cidaas IDP
CidaasProvider ProviderType = "cidaas"

// DigitalOceanProvider is the provider type for DigitalOcean
DigitalOceanProvider ProviderType = "digitalocean"

Expand Down Expand Up @@ -136,9 +139,6 @@ const (

// OIDCProvider is the provider type for OIDC
OIDCProvider ProviderType = "oidc"

// CidaasProvider is the provider type for Cidaas IDP
CidaasProvider ProviderType = "cidaas"
)

type KeycloakOptions struct {
Expand Down
6 changes: 3 additions & 3 deletions providers/providers.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ func NewProvider(providerConfig options.Provider) (Provider, error) {
return NewAzureProvider(providerData, providerConfig.AzureConfig), nil
case options.BitbucketProvider:
return NewBitbucketProvider(providerData, providerConfig.BitbucketConfig), nil
case options.CidaasProvider:
return NewCIDAASProvider(providerData), nil
case options.DigitalOceanProvider:
return NewDigitalOceanProvider(providerData), nil
case options.FacebookProvider:
Expand All @@ -65,8 +67,6 @@ func NewProvider(providerConfig options.Provider) (Provider, error) {
return NewNextcloudProvider(providerData), nil
case options.OIDCProvider:
return NewOIDCProvider(providerData, providerConfig.OIDCConfig), nil
case options.CidaasProvider:
return NewCIDAASProvider(providerData), nil
default:
return nil, fmt.Errorf("unknown provider type %q", providerConfig.Type)
}
Expand Down Expand Up @@ -183,7 +183,7 @@ func providerRequiresOIDCProviderVerifier(providerType options.ProviderType) (bo
case options.BitbucketProvider, options.DigitalOceanProvider, options.FacebookProvider, options.GitHubProvider,
options.GoogleProvider, options.KeycloakProvider, options.LinkedInProvider, options.LoginGovProvider, options.NextCloudProvider:
return false, nil
case options.ADFSProvider, options.AzureProvider, options.GitLabProvider, options.KeycloakOIDCProvider, options.OIDCProvider, options.CidaasProvider:
case options.ADFSProvider, options.AzureProvider, options.CidaasProvider, options.GitLabProvider, options.KeycloakOIDCProvider, options.OIDCProvider:
return true, nil
default:
return false, fmt.Errorf("unknown provider type: %s", providerType)
Expand Down

0 comments on commit d660000

Please sign in to comment.