Documentation
¶
Index ¶
- func NewConfig(clientID string) *oidc.Config
- func RevocationEndpoint(p Provider) (string, error)
- func RevokeTokens(ctx context.Context, revocationEndpoint string, token *oauth2.Token, ...) error
- func TokenSource(ctx context.Context, config *oauth2.Config, token *oauth2.Token) (*oauth2.Token, bool, error)
- type Provider
- type UserInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RevocationEndpoint ¶
RevocationEndpoint parses the OIDC Provider claims from the discovery document and tries to find the revocation_endpoint.
Types ¶
type Provider ¶
type UserInfo ¶
type UserInfo struct { Subject string `json:"sub"` Profile string `json:"profile"` Email string `json:"email"` EmailVerified bool `json:"email_verified"` RawClaims []byte }
UserInfo represents the OpenID Connect userinfo claims.
func GetUserInfo ¶
GetUserInfo uses the token source to query the provider's user info endpoint. We reimplement UserInfo 1 instead of using the go-oidc's library UserInfo, in order to include HTTP response information in case of an error during contacting the UserInfo endpoint.
func ParseUserInfo ¶
ParseUserInfo unmarshals the response of the UserInfo endpoint and enforces boolean value for the EmailVerified claim.
Click to show internal directories.
Click to hide internal directories.