GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — quic: handle h3 max header size option · nodejs/node@dbe0b37

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • src/quic
    • application.cc
    • session.h
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/quic/application.cc‎

Copy file name to clipboardExpand all lines: src/quic/application.cc
+7Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,13 @@ Maybe<Session::Application_Options> Session::Application_Options::From(
115115

116116
#undef SET
117117

118+
// Ensure the advertised max_field_section_size in SETTINGS is at least
119+
// as large as max_header_length. Otherwise the peer would be told to
120+
// restrict headers to a smaller size than what CanAddHeader accepts.
121+
if (options.max_field_section_size < options.max_header_length) {
122+
options.max_field_section_size = options.max_header_length;
123+
}
124+
118125
return Just<Application_Options>(options);
119126
}
120127

Collapse file

‎src/quic/session.h‎

Copy file name to clipboardExpand all lines: src/quic/session.h
+5-1Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,11 @@ class Session final : public AsyncWrap, private SessionTicket::AppData::Source {
7272
uint64_t max_header_length = DEFAULT_MAX_HEADER_LENGTH;
7373

7474
// HTTP/3 specific options.
75-
uint64_t max_field_section_size = 0;
75+
// The maximum header section size advertised to the peer in SETTINGS.
76+
// Defaults to match max_header_length so the SETTINGS frame accurately
77+
// reflects the enforcement limit. A value of 0 would incorrectly tell
78+
// the peer not to send any headers at all.
79+
uint64_t max_field_section_size = DEFAULT_MAX_HEADER_LENGTH;
7680
uint64_t qpack_max_dtable_capacity = 4096;
7781
uint64_t qpack_encoder_max_dtable_capacity = 4096;
7882
uint64_t qpack_blocked_streams = 100;

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.