Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add openid connect endpoint/algo setters #440

Open
wants to merge 1 commit into
base: v3
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions oidc/oidc.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,42 @@ func (p *Provider) UserInfoEndpoint() string {
return p.userInfoURL
}

// setAuthURL permit to overide the OpenID Connect authURL endpoint for the given
// provider.
func (p *Provider) setAuthURL(endpoint string) {
p.authURL=endpoint
}

// setDeviceAuthURL permit to overide the OpenID Connect deviceAuthURL endpoint for the given
// provider.
func (p *Provider) setDeviceAuthURL(endpoint string) {
p.deviceAuthURL=endpoint
}

// setTokenURL permit to overide the OpenID Connect tokenURL endpoint for the given
// provider.
func (p *Provider) setTokenURL(endpoint string) {
p.tokenURL=endpoint
}

// setTokenURL permit to overide the OpenID Connect userInfoURL endpoint for the given
// provider.
func (p *Provider) setUserInfoEndpoint(endpoint string) {
p.userInfoURL=endpoint
}

// setJWKSURL permit to overide the OpenID Connect jwksURL endpoint for the given
// provider.
func (p *Provider) setJWKSURL(endpoint string) {
p.jwksURL=endpoint
}

// setJWKSURL permit to overide the OpenID Connect JWKSURL endpoint for the given
// provider.
func (p *Provider) setAlgorithms(algorithm []string) {
p.algorithms=algorithm
}

// UserInfo represents the OpenID Connect userinfo claims.
type UserInfo struct {
Subject string `json:"sub"`
Expand Down