-
Notifications
You must be signed in to change notification settings - Fork 113
Add redacted field options to egress fields #1286
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
Conversation
🦋 Changeset detectedLatest commit: 8a286d3 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR 💥 An error occurred when fetching the changed packages and changesets in this PR |
794b623 to
5c17efb
Compare
logger/proto.go
Outdated
|
|
||
| if proto.HasExtension(f.Options(), logger.E_Redact) { | ||
| e.AddString(k, "<redacted>") | ||
| e.AddString(k, fmt.Sprintf("<%s>", f.TextName())) |
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.
the name is already the field key in the log and replacing the value with the text "redacted" makes it clear why it's been omitted to readers unfamiliar with the message schema.
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.
The trade off is consistency with the existing logic. I have no strong opinion either way. @frostbyte73 what is your opinion here since I believe you wrote the existing redaction code?
| @@ -1,7 +1,7 @@ | |||
| syntax = "proto3"; | |||
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.
this file is missing the license header
…amin/redact_proto
…amin/redact_proto
Makes sure RPC systems that use the livekit logger wrappers do not log these fields.
This also makes indenting and spaces more consistent by using passing the file through clang-format. Happy to revert this if we want to avoid large cosmetic PRs
These other following changes are suggestions and open for debate: