dist/tools/ethos: fix minor code quality issues#21979
Merged
maribu merged 1 commit intoRIOT-OS:masterfrom Jan 12, 2026
Merged
Conversation
miri64
reviewed
Jan 12, 2026
Member
miri64
left a comment
There was a problem hiding this comment.
Not mandatory, but Vera++ points out some more code style issues (see annotations in "Files changed" view. Can you fix them as well?
miri64
reviewed
Jan 12, 2026
Member
miri64
left a comment
There was a problem hiding this comment.
Except for style issues to your style fixes ;-): ACK
8ea71ed to
8c22874
Compare
Member
Author
|
Fixed and squashed |
- fix some minor code style issues
- add an overflow check for the frame received from the MCU
- a malicious MCU could overflow the stack allocated buffer in
`serial_t serial` in member `char frame[MTU];`.
- most people don't plug in random unstrusted hardware into their
machines, so this is not a really plausible attack vector
- it is a valid bug, though, and therefore fixed
Co-authored-by: Martine Lenders <[email protected]>
8c22874 to
dc068a6
Compare
Member
Author
Done and squashed. |
miri64
approved these changes
Jan 12, 2026
This file contains hidden or 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
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.
Contribution description
serial_t serialin memberchar frame[MTU];.Testing procedure
Code review should be sufficient here. But testing that the ethos tool still works just to be safe won't hurt either.
Issues/PRs references
https://seclists.org/fulldisclosure/2026/Jan/16