-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[processor/redaction] Introduce blocked_key_patterns
parameter
#37664
base: main
Are you sure you want to change the base?
Conversation
7c82c57
to
b3a192a
Compare
b3a192a
to
71decca
Compare
…shing instead of masking values via 'hash_function' parameter Signed-off-by: odubajDT <[email protected]>
Signed-off-by: odubajDT <[email protected]>
be2df19
to
b8eed15
Compare
blocked_key_patterns
and support hashing instead of masking values via hash_function
parameterblocked_key_patterns
parameter
component: processor/redaction | ||
|
||
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). | ||
note: "Introduce 'blocked_key_patterns' and support hashing instead of masking values via 'hash_function' parameter" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Release note needs an update after the split
@@ -73,6 +73,11 @@ processors: | |||
# Any keys in this list are allowed so they don't need to be in both lists. | |||
ignored_keys: | |||
- safe_attribute | |||
# blocked_key_patterns is a list of blocked span attribute key patters. Span attributes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# blocked_key_patterns is a list of blocked span attribute key patters. Span attributes | |
# blocked_key_patterns is a list of blocked span attribute key patterns. Span attributes |
The value is then masked with a fixed length of asterisks or hashed by a function | ||
defined in `hash_function`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit (to make it a bit more future-proof)
The value is then masked with a fixed length of asterisks or hashed by a function | |
defined in `hash_function`. | |
The value is then masked according to the configuration. |
@@ -43,6 +45,11 @@ func newRedaction(ctx context.Context, config *Config, logger *zap.Logger) (*red | |||
// TODO: Placeholder for an error metric in the next PR | |||
return nil, fmt.Errorf("failed to process block list: %w", err) | |||
} | |||
blockKeysRegexList, err := makeRegexList(ctx, config.BlockedKeyPatterns) | |||
if err != nil { | |||
// TODO: Placeholder for an error metric in the next PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we have an issue for any TODO in the code?
Description
blocked_key_patterns
parameter to mask values of attributes, which keys match at least one of the defined patternsLink to tracking issue
Fixes #35830
Follow-up
#38161