forked from TrueCloudLab/certificates
Drop any query string from the admin tokens
This commit makes sure the admin token audience is passed without a query string (or any fragment).
This commit is contained in:
parent
50a271edca
commit
4770b405ba
1 changed files with 7 additions and 0 deletions
|
@ -90,6 +90,13 @@ func (c *AdminClient) generateAdminToken(aud *url.URL) (string, error) {
|
|||
return "", err
|
||||
}
|
||||
|
||||
// Drop any query string parameter from the token audience
|
||||
aud = &url.URL{
|
||||
Scheme: aud.Scheme,
|
||||
Host: aud.Host,
|
||||
Path: aud.Path,
|
||||
}
|
||||
|
||||
now := time.Now()
|
||||
tokOptions := []token.Options{
|
||||
token.WithJWTID(jwtID),
|
||||
|
|
Loading…
Reference in a new issue