-
Notifications
You must be signed in to change notification settings - Fork 528
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
Allow only valid trace ID characters when decoding #854
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zalegrala
requested review from
annanay25,
dgzlopes,
joe-elliott,
mapno and
mdisibio
as code owners
August 4, 2021 13:33
dgzlopes
approved these changes
Aug 4, 2021
zalegrala
changed the title
Trim leading or trailing space from trace ID
Catch a few non-hex characters when translating trace IDs
Aug 4, 2021
yvrhdn
reviewed
Aug 4, 2021
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.
Besides the small note, this looks okay to me 🙂
I'm trying to find the most common invalid characters, but I'm not sure we log this somewhere...
edit: we don't log this because validation happens before logging. This will be improved when we merge the search PR.
yvrhdn
approved these changes
Aug 4, 2021
mdisibio
requested changes
Aug 4, 2021
zalegrala
changed the title
Catch a few non-hex characters when translating trace IDs
Allow only valid trace ID characters when decoding
Aug 4, 2021
zalegrala
force-pushed
the
trimTraceID
branch
3 times, most recently
from
August 4, 2021 20:14
c34f5a1
to
032572b
Compare
Without this change, invalid characters received from the user input causes a bad error message to the user. Here we check that all of the characters that are to be decoded are valid hex characters and improve the error to the user in the event the trace ID submitted has invalid characters.
mdisibio
approved these changes
Aug 5, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Without this change, invalid characters received from the user input causes a bad error message to the user. Here we check that all of the characters that are to be decoded are valid hex characters and improve the error to the user in the event the trace ID submitted has invalid characters.
Fixes #846
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]