Skip to content

Commit

Permalink
Sync Develop with Master (#66)
Browse files Browse the repository at this point in the history
Co-authored-by: Carlos Andres Padillla Sainz <[email protected]>
Co-authored-by: Douglas Thrift <[email protected]>
Co-authored-by: Caleb Lloyd <[email protected]>
Co-authored-by: Charl Matthee <[email protected]>
Co-authored-by: bogdanprodan-okta <[email protected]>
Co-authored-by: bogdanprodan-okta <[email protected]>
  • Loading branch information
7 people authored Feb 19, 2021
1 parent 016cc2e commit fe3d117
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions jwtverifier.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,11 @@ func (j *JwtVerifier) decodeJwt(jwt string) (interface{}, error) {
if err != nil {
return nil, err
}

resp, err := j.Adaptor.Decode(jwt, metaData["jwks_uri"].(string))
jwksURI, ok := metaData["jwks_uri"].(string)
if !ok {
return nil, fmt.Errorf("failed to decode JWT: missing 'jwks_uri' from metadata")
}
resp, err := j.Adaptor.Decode(jwt, jwksURI)

if err != nil {
return nil, fmt.Errorf("could not decode token: %s", err.Error())
Expand Down

0 comments on commit fe3d117

Please sign in to comment.