mirror of
https://github.com/distribution/distribution.git
synced 2025-09-13 13:49:00 +00:00
Support session token
Signed-off-by: Troels Thomsen <troels@thomsen.io>
This commit is contained in:
@@ -137,6 +137,9 @@ func (v2 *signer) Sign() error {
|
||||
host, canonicalPath := parsedURL.Host, parsedURL.Path
|
||||
v2.Request.Header["Host"] = []string{host}
|
||||
v2.Request.Header["date"] = []string{v2.Time.In(time.UTC).Format(time.RFC1123)}
|
||||
if credValue.SessionToken != "" {
|
||||
v2.Request.Header["x-amz-security-token"] = []string{credValue.SessionToken}
|
||||
}
|
||||
|
||||
smap = make(map[string]string)
|
||||
for k, v := range headers {
|
||||
|
Reference in New Issue
Block a user