UDP/QUIC: Make sure quiche gets the entire rx buffer from the udp packet.#9765
Merged
brbzull0 merged 1 commit intoapache:masterfrom Jun 2, 2023
Merged
Conversation
packet. It seems that it was only getting the first slice of the entire chain. Currently each of the iov buffer size is hardcoded to 2k, if happens that we need to fit more than 2k inside the buffer the current code will only hand over the first part of the chain which will make QUICHE to complain as the data is incomplete. This change makes sure that quiche gets the entire buffer.
maskit
reviewed
Jun 1, 2023
| return reinterpret_cast<uint8_t *>(block->buf()); | ||
| } | ||
|
|
||
| // Store it. Should we try to avoid allocating here? |
Member
There was a problem hiding this comment.
Should we try to avoid allocating here?
Yes, it's very unfortunate to alloc another buffer and copy data. But as we talked offline, let's fix the bug for now and improve it with a GRO friendly design.
maskit
approved these changes
Jun 1, 2023
Contributor
Author
|
[approve ci autest] |
Contributor
Author
|
[approve ci ubuntu] |
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.
It seems that it was only getting the first slice of the entire chain. Currently each of the iov buffer size is hardcoded to 2k, if happens that we need to fit more than 2k inside the buffer the current code will only hand over the first part of the chain which will make QUICHE to complain as the data is incomplete.
This change makes sure that quiche gets the entire buffer by building the entire buffer together.
Issue can be reproduced by including the
--max-udp-payload-size 3kin theh2loadtool. Actually, any size above 2k should hit the issue.example:
FYI: For now this seems fine but as soon as we introduce GRO this will more likely to change.