Skip to content

Commit

Permalink
expand header matches
Browse files Browse the repository at this point in the history
  • Loading branch information
michel-laterman committed Dec 5, 2024
1 parent 1f86340 commit bdfc5b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ func redactOutput(cfg *Config) Output {
}

for k := range redacted.Elasticsearch.Headers {
if strings.Contains(strings.ToLower(k), "auth") {
if strings.Contains(strings.ToLower(k), "auth") || strings.Contains(strings.ToLower(k), "token") || strings.Contains(strings.ToLower(k), "key") { // best-effort scan to redact sensitive headers
redacted.Elasticsearch.Headers[k] = kRedacted
}
}
Expand Down

0 comments on commit bdfc5b3

Please sign in to comment.