Block copy source authorization from logging
This commit is contained in:
Родитель
dc95902f1d
Коммит
9c760f3e94
|
@ -66,7 +66,7 @@ func writeHeader(b *bytes.Buffer, header map[string][]string) {
|
|||
for _, k := range keys {
|
||||
// Redact the value of any Authorization header to prevent security information from persisting in logs
|
||||
value := interface{}("REDACTED")
|
||||
if !strings.EqualFold(k, "Authorization") {
|
||||
if !strings.EqualFold(k, "Authorization") && !strings.EqualFold(k, "X-Ms-Copy-Source-Authorization") {
|
||||
value = header[k]
|
||||
}
|
||||
fmt.Fprintf(b, " %s: %+v\n", k, value)
|
||||
|
|
Загрузка…
Ссылка в новой задаче