mirror of
https://github.com/actions/actions-runner-controller.git
synced 2025-12-11 12:06:57 +00:00
Use UUID v5 for client identifiers (#2241)
This commit is contained in:
@@ -3,6 +3,7 @@ package actions
|
|||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"context"
|
"context"
|
||||||
|
"crypto/sha256"
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"crypto/x509"
|
"crypto/x509"
|
||||||
"encoding/base64"
|
"encoding/base64"
|
||||||
@@ -185,7 +186,7 @@ func (c *Client) Identifier() string {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
return uuid.NewMD5(uuid.NameSpaceOID, []byte(identifier)).String()
|
return uuid.NewHash(sha256.New(), uuid.NameSpaceOID, []byte(identifier), 6).String()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Client) Do(req *http.Request) (*http.Response, error) {
|
func (c *Client) Do(req *http.Request) (*http.Response, error) {
|
||||||
|
|||||||
Reference in New Issue
Block a user