Skip to content

Commit

Permalink
small changes from review
Browse files Browse the repository at this point in the history
  • Loading branch information
scotthew1 authored and Scott Reisor committed Mar 25, 2020
1 parent 21ab763 commit 104d398
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions server/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -511,8 +511,8 @@ func (s *Server) handleSAMLCallback(r *http.Request) (string, string, int, error
s.logger.Warnf("SAML IdP initiated login attempt made to client %q, but support for this flow is not configured. Update the client config to support this login flow.", relayState)
return "", "", http.StatusBadRequest, errors.New("user session error")
}
// TODO: should we check that 'idtoken' is one of the scopes? or just put the
// burden on the user to confiugre these scopes correctly?
// TODO: should we check that 'openid' is one of the scopes? or just put the
// burden on the user to configure these scopes correctly?
scopes := client.SAMLInitiated.Scopes
if len(scopes) == 0 {
scopes = saml.DefaultIDPInitiatedScopes
Expand Down
4 changes: 2 additions & 2 deletions storage/kubernetes/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,13 +168,13 @@ type Client struct {
Name string `json:"name,omitempty"`
LogoURL string `json:"logoURL,omitempty"`

SAMLInitiated SAMLInitiatedConfig `json:"samlInitiated"`
SAMLInitiated SAMLInitiatedConfig `json:"samlInitiated,omitempty"`
}

// SAMLInitiatedConfig is mirrored from storage.SAMLInitiatedConfig
type SAMLInitiatedConfig struct {
RedirectURI string `json:"redirectURI"`
Scopes []string `json:"scopes"`
Scopes []string `json:"scopes,omitempty"`
}

// ClientList is a list of Clients.
Expand Down

0 comments on commit 104d398

Please sign in to comment.