-
Notifications
You must be signed in to change notification settings - Fork 291
Support query argument redaction in DM logging #11489
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
Support query argument redaction in DM logging #11489
Comments
Hey @michaelmdeng , I want to follow up on this issue. Should we redact the SQL query, or is redacting the query arguments sufficient? |
There are still some places that forget to proactively use redact function. |
@lance6716 could you point out a few places that we might need to redact sensitive info? thanks |
like Line 249 in 8e3b63a
|
@lance6716 tried to find similar pattern as you presented, didn't find any other similar lines that print out query arguments. i create a update pr. |
Uh oh!
There was an error while loading. Please reload this page.
Is your feature request related to a problem?
When DM logs queries, either with debug logging for all queries, or when encountering errors with warning/error logging, it logs the entire text of the query with arguments. This risks logging sensitive data.
For example, many of the log lines in https://github.com/pingcap/tiflow/blob/master/dm/pkg/conn/baseconn.go will log (truncated) full queries and arguments
Describe the feature you'd like
Configuration, similar to tidb log redaction, that will redact sensitive arguments from queries when DM logs them.
Describe alternatives you've considered
Since they are logged at all possible log levels, no alternative but turning off logging entirely.
Teachability, Documentation, Adoption, Migration Strategy
N/A
The text was updated successfully, but these errors were encountered: