mirror of
https://github.com/smallstep/certificates.git
synced 2024-11-15 18:12:59 +00:00
Add audience in error.
This commit is contained in:
parent
60880d1f0a
commit
f8fba4df6b
@ -55,7 +55,7 @@ func (a *Authority) Authorize(ott string) ([]provisioner.SignOption, error) {
|
|||||||
// This method will also validate the audiences for JWK provisioners.
|
// This method will also validate the audiences for JWK provisioners.
|
||||||
p, ok := a.provisioners.LoadByToken(token, &claims.Claims)
|
p, ok := a.provisioners.LoadByToken(token, &claims.Claims)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, &apiError{errors.New("authorize: provisioner not found or invalid audience"),
|
return nil, &apiError{errors.Errorf("authorize: provisioner not found or invalid audience %s", claims.Audience),
|
||||||
http.StatusUnauthorized, errContext}
|
http.StatusUnauthorized, errContext}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user