fix: add code_challenge_methods_supported to discovery endpoint (#43)

* fix: add code_challenge_methods_supported to discovery endpoint

* fix mock
This commit is contained in:
Livio Amstutz 2020-08-20 16:27:51 +02:00 committed by GitHub
parent 5a8e69978f
commit 57cf8ee9c7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 32 additions and 0 deletions

View file

@ -26,6 +26,8 @@ const (
AuthMethodBasic AuthMethod = "client_secret_basic"
AuthMethodPost = "client_secret_post"
AuthMethodNone = "none"
CodeMethodS256 = "S256"
)
var (
@ -58,6 +60,7 @@ type Config struct {
Issuer string
CryptoKey [32]byte
DefaultLogoutRedirectURI string
CodeMethodS256 bool
// ScopesSupported: oidc.SupportedScopes,
// ResponseTypesSupported: responseTypes,
// GrantTypesSupported: oidc.SupportedGrantTypes,
@ -222,6 +225,10 @@ func (p *DefaultOP) AuthMethodPostSupported() bool {
return true //TODO: config
}
func (p *DefaultOP) CodeMethodS256Supported() bool {
return p.config.CodeMethodS256
}
func (p *DefaultOP) HttpHandler() http.Handler {
return p.http
}