mirror of
https://github.com/TwiN/gatus.git
synced 2024-10-05 09:42:26 +02:00
14 lines
529 B
Go
14 lines
529 B
Go
package security
|
|
|
|
// EndpointOIDCConfig is the configuration for endpoint OIDC authentication
|
|
type EndpointOIDCConfig struct {
|
|
IssuerURL string `yaml:"issuer-url"` // e.g. https://dev-12345678.okta.com
|
|
ClientID string `yaml:"client-id"`
|
|
ClientSecret string `yaml:"client-secret"`
|
|
Scopes []string `yaml:"scopes"` // e.g. ["openid"]
|
|
}
|
|
|
|
func (c *EndpointOIDCConfig) IsValid() bool {
|
|
return len(c.IssuerURL) > 0 && len(c.ClientID) > 0 && len(c.ClientSecret) > 0 && len(c.Scopes) > 0
|
|
}
|