Repository navigation
Fix[PushMessageImpl]: validate PUSH message sizes - #188
Merged
Merged
Conversation
678098
commented
Nov 16, 2026
| int optionSize = header.optionsWords() * Protocol.WORD_SIZE; | ||
| if (appDataSize <= optionSize) { | ||
| throw new IOException("Invalid options size: " + optionSize); | ||
| } |
Contributor
Author
There was a problem hiding this comment.
If the appDataSize <= optionSize condition is false
=> optionSize < appDataSize
=> 0 < appDataSize - optionSize
=> 0 < dataSize (line 132)
kaikulimu
approved these changes
Nov 16, 2026
Reject PUSH messages where the header is bigger than the message, or the options leave no room for data. Signed-off-by: Evgeny Malygin <emalygin@bloomberg.net>
678098
force-pushed
the
261116_push_validation
branch
from
November 17, 2026 15:26
ab15fc9 to
7b72671
Compare
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.
Reject PUSH messages where the header is bigger than the message, or the options leave no room for data.