mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 21:37:32 +00:00
fix: response type mapping (#426)
* fix: return authorizations on userinfo * fix: response type mapping * fix tests * fix angular * regenerate mgmt proto * enable login link again
This commit is contained in:
@@ -87,7 +87,7 @@ func TestApplicationValid(t *testing.T) {
|
||||
Name: "Name",
|
||||
Type: AppTypeOIDC,
|
||||
OIDCConfig: &OIDCConfig{
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeToken},
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeIDTokenToken},
|
||||
GrantTypes: []OIDCGrantType{OIDCGrantTypeImplicit},
|
||||
},
|
||||
},
|
||||
@@ -103,7 +103,7 @@ func TestApplicationValid(t *testing.T) {
|
||||
Name: "Name",
|
||||
Type: AppTypeOIDC,
|
||||
OIDCConfig: &OIDCConfig{
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeToken},
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeIDTokenToken},
|
||||
GrantTypes: []OIDCGrantType{OIDCGrantTypeAuthorizationCode},
|
||||
},
|
||||
},
|
||||
@@ -135,7 +135,7 @@ func TestApplicationValid(t *testing.T) {
|
||||
Name: "Name",
|
||||
Type: AppTypeOIDC,
|
||||
OIDCConfig: &OIDCConfig{
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeCode, OIDCResponseTypeToken},
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeCode, OIDCResponseTypeIDTokenToken},
|
||||
GrantTypes: []OIDCGrantType{OIDCGrantTypeAuthorizationCode, OIDCGrantTypeImplicit},
|
||||
},
|
||||
},
|
||||
@@ -151,7 +151,7 @@ func TestApplicationValid(t *testing.T) {
|
||||
Name: "Name",
|
||||
Type: AppTypeOIDC,
|
||||
OIDCConfig: &OIDCConfig{
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeCode, OIDCResponseTypeIDToken, OIDCResponseTypeToken},
|
||||
ResponseTypes: []OIDCResponseType{OIDCResponseTypeCode, OIDCResponseTypeIDToken, OIDCResponseTypeIDTokenToken},
|
||||
GrantTypes: []OIDCGrantType{OIDCGrantTypeAuthorizationCode, OIDCGrantTypeImplicit},
|
||||
},
|
||||
},
|
||||
|
@@ -24,7 +24,7 @@ type OIDCResponseType int32
|
||||
const (
|
||||
OIDCResponseTypeCode OIDCResponseType = iota
|
||||
OIDCResponseTypeIDToken
|
||||
OIDCResponseTypeToken
|
||||
OIDCResponseTypeIDTokenToken
|
||||
)
|
||||
|
||||
type OIDCGrantType int32
|
||||
@@ -69,7 +69,7 @@ func (c *OIDCConfig) getRequiredGrantTypes() []OIDCGrantType {
|
||||
switch r {
|
||||
case OIDCResponseTypeCode:
|
||||
grantTypes = append(grantTypes, OIDCGrantTypeAuthorizationCode)
|
||||
case OIDCResponseTypeIDToken, OIDCResponseTypeToken:
|
||||
case OIDCResponseTypeIDToken, OIDCResponseTypeIDTokenToken:
|
||||
if !implicit {
|
||||
grantTypes = append(grantTypes, OIDCGrantTypeImplicit)
|
||||
}
|
||||
|
Reference in New Issue
Block a user