Skip to content
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

use PADDING frames to pad packets #2876

Merged
merged 3 commits into from
Nov 16, 2020
Merged

Conversation

marten-seemann
Copy link
Member

Fixes #2875.

This is a non-trivial rewrite of how we pack packets. Now we compose the payload of an entire datagram (i.e. multiple coalesced packets), before serializing anything. This allows us to add PADDING frames to the Initial packet.

In order for this to work properly, we need to make sure encode the Length field in the Long Header in 2 bytes (even if the actual length would have in 1 byte).

@codecov
Copy link

codecov bot commented Nov 15, 2020

Codecov Report

Merging #2876 (d1a784d) into master (e676a83) will increase coverage by 0.06%.
The diff coverage is 87.43%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2876      +/-   ##
==========================================
+ Coverage   85.71%   85.77%   +0.06%     
==========================================
  Files         134      134              
  Lines        9112     9188      +76     
==========================================
+ Hits         7810     7881      +71     
+ Misses        960      959       -1     
- Partials      342      348       +6     
Impacted Files Coverage Δ
packet_packer.go 84.45% <85.99%> (+1.04%) ⬆️
internal/utils/varint.go 78.38% <100.00%> (+5.96%) ⬆️
internal/wire/extended_header.go 87.60% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e676a83...d1a784d. Read the comment docs.

@marten-seemann
Copy link
Member Author

Merging, as we need to release a new version asap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

padding of Server Initials fails if the certifictate is very small
1 participant