configuration

package
v0.0.0-...-7a7eea5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 20, 2021 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const WellKnownOpenidConfigurationPath = "/.well-known/openid-configuration"

https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationRequest

Variables

View Source
var File_lib_openid_configuration_openid_configuration_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type OpenIDConfiguration

type OpenIDConfiguration struct {

	// REQUIRED. URL using the https scheme with no query or fragment component that the OP asserts as its Issuer Identifier. If Issuer discovery is supported (see Section 2), this value MUST be identical to the issuer value returned by WebFinger. This also MUST be identical to the iss Claim value in ID Tokens issued from this Issuer.
	Issuer string `protobuf:"bytes,1,opt,name=issuer,proto3" json:"issuer,omitempty"`
	// REQUIRED. URL of the OP's OAuth 2.0 Authorization Endpoint [OpenID.Core].
	AuthorizationEndpoint string `protobuf:"bytes,2,opt,name=authorization_endpoint,json=authorizationEndpoint,proto3" json:"authorization_endpoint,omitempty"`
	// URL of the OP's OAuth 2.0 Token Endpoint [OpenID.Core]. This is REQUIRED unless only the Implicit Flow is used.
	TokenEndpoint string `protobuf:"bytes,3,opt,name=token_endpoint,json=tokenEndpoint,proto3" json:"token_endpoint,omitempty"`
	// RECOMMENDED. URL of the OP's UserInfo Endpoint [OpenID.Core]. This URL MUST use the https scheme and MAY contain port, path, and query parameter components.
	UserinfoEndpoint string `protobuf:"bytes,5,opt,name=userinfo_endpoint,json=userinfoEndpoint,proto3" json:"userinfo_endpoint,omitempty"`
	// REQUIRED. URL of the OP's JSON Web Key Set [JWK] document. This contains the signing key(s) the RP uses to validate signatures from the OP. The JWK Set MAY also contain the Server's encryption key(s), which are used by RPs to encrypt requests to the Server. When both signing and encryption keys are made available, a use (Key Use) parameter value is REQUIRED for all keys in the referenced JWK Set to indicate each key's intended usage. Although some algorithms allow the same key to be used for both signatures and encryption, doing so is NOT RECOMMENDED, as it is less secure. The JWK x5c parameter MAY be used to provide X.509 representations of keys provided. When used, the bare key values MUST still be present and MUST match those in the certificate.
	JwksUri string `protobuf:"bytes,4,opt,name=jwks_uri,json=jwksUri,proto3" json:"jwks_uri,omitempty"`
	// REQUIRED. JSON array containing a list of the JWS signing algorithms (alg values) supported by the OP for the ID Token to encode the Claims in a JWT [JWT]. The algorithm RS256 MUST be included. The value none MAY be supported, but MUST NOT be used unless the Response Type used returns no ID Token from the Authorization Endpoint (such as when using the Authorization Code Flow).
	IdTokenSigningAlgValuesSupported []string `` /* 165-byte string literal not displayed */
	// RECOMMENDED. URL of the OP's Dynamic Client Registration Endpoint [OpenID.Registration].
	RegistrationEndpoint string `protobuf:"bytes,7,opt,name=registration_endpoint,json=registrationEndpoint,proto3" json:"registration_endpoint,omitempty"`
	// RECOMMENDED. JSON array containing a list of the OAuth 2.0 [RFC6749] scope values that this server supports. The server MUST support the openid scope value. Servers MAY choose not to advertise some supported scope values even when this parameter is used, although those defined in [OpenID.Core] SHOULD be listed, if supported.
	ScopesSupported []string `protobuf:"bytes,8,rep,name=scopes_supported,json=scopesSupported,proto3" json:"scopes_supported,omitempty"`
	// REQUIRED. JSON array containing a list of the OAuth 2.0 response_type values that this OP supports. Dynamic OpenID Providers MUST support the code, id_token, and the token id_token Response Type values.
	ResponseTypesSupported []string `` /* 129-byte string literal not displayed */
	// RECOMMENDED. JSON array containing a list of the Claim Names of the Claims that the OpenID Provider MAY be able to supply values for. Note that for privacy or other reasons, this might not be an exhaustive list.
	ClaimsSupported []string `protobuf:"bytes,10,rep,name=claims_supported,json=claimsSupported,proto3" json:"claims_supported,omitempty"`
	// contains filtered or unexported fields
}

https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata

func Fetch

func Fetch(ctx context.Context, issuer string) (*OpenIDConfiguration, error)

func (*OpenIDConfiguration) Descriptor deprecated

func (*OpenIDConfiguration) Descriptor() ([]byte, []int)

Deprecated: Use OpenIDConfiguration.ProtoReflect.Descriptor instead.

func (*OpenIDConfiguration) GetAuthorizationEndpoint

func (x *OpenIDConfiguration) GetAuthorizationEndpoint() string

func (*OpenIDConfiguration) GetClaimsSupported

func (x *OpenIDConfiguration) GetClaimsSupported() []string

func (*OpenIDConfiguration) GetIdTokenSigningAlgValuesSupported

func (x *OpenIDConfiguration) GetIdTokenSigningAlgValuesSupported() []string

func (*OpenIDConfiguration) GetIssuer

func (x *OpenIDConfiguration) GetIssuer() string

func (*OpenIDConfiguration) GetJwksUri

func (x *OpenIDConfiguration) GetJwksUri() string

func (*OpenIDConfiguration) GetRegistrationEndpoint

func (x *OpenIDConfiguration) GetRegistrationEndpoint() string

func (*OpenIDConfiguration) GetResponseTypesSupported

func (x *OpenIDConfiguration) GetResponseTypesSupported() []string

func (*OpenIDConfiguration) GetScopesSupported

func (x *OpenIDConfiguration) GetScopesSupported() []string

func (*OpenIDConfiguration) GetTokenEndpoint

func (x *OpenIDConfiguration) GetTokenEndpoint() string

func (*OpenIDConfiguration) GetUserinfoEndpoint

func (x *OpenIDConfiguration) GetUserinfoEndpoint() string

func (*OpenIDConfiguration) ProtoMessage

func (*OpenIDConfiguration) ProtoMessage()

func (*OpenIDConfiguration) ProtoReflect

func (x *OpenIDConfiguration) ProtoReflect() protoreflect.Message

func (*OpenIDConfiguration) Reset

func (x *OpenIDConfiguration) Reset()

func (*OpenIDConfiguration) String

func (x *OpenIDConfiguration) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL