Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tom@curii.com>
return errors.New("no certificate received, cannot compute authorization header")
}
h := hmac.New(sha256.New, []byte(conn.cluster.SystemRootToken))
- fmt.Fprint(h, "%s", opts.UUID)
+ fmt.Fprint(h, opts.UUID)
authKey := fmt.Sprintf("%x", h.Sum(nil))
h = hmac.New(sha256.New, []byte(authKey))
h.Write(rawCerts[0])
func (wp *Pool) gatewayAuthSecret(uuid string) string {
h := hmac.New(sha256.New, []byte(wp.systemRootToken))
- fmt.Fprint(h, "%s", uuid)
+ fmt.Fprint(h, uuid)
return fmt.Sprintf("%x", h.Sum(nil))
}