mirror of
https://github.com/nodejs/node.git
synced 2026-11-26 21:58:26 -05:00
quic: handle h3 max header size option
Signed-off-by: James M Snell <jasnell@gmail.com> PR-URL: https://github.com/nodejs/node/pull/63483 Backport-PR-URL: https://github.com/nodejs/node/pull/64675 Reviewed-By: Stephen Belanger <admin@stephenbelanger.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
This commit is contained in:
1 parent
39dca4150c
commit
dbe0b371ee
2 files changed
+12
-1
No files matched your search
@@ -115,6 +115,13 @@ Maybe<Session::Application_Options> Session::Application_Options::From(
|
||||
|
||||
#undef SET
|
||||
|
||||
// Ensure the advertised max_field_section_size in SETTINGS is at least
|
||||
// as large as max_header_length. Otherwise the peer would be told to
|
||||
// restrict headers to a smaller size than what CanAddHeader accepts.
|
||||
if (options.max_field_section_size < options.max_header_length) {
|
||||
options.max_field_section_size = options.max_header_length;
|
||||
}
|
||||
|
||||
return Just<Application_Options>(options);
|
||||
}
|
||||
|
||||
|
||||
+5
-1
@@ -72,7 +72,11 @@ class Session final : public AsyncWrap, private SessionTicket::AppData::Source {
|
||||
uint64_t max_header_length = DEFAULT_MAX_HEADER_LENGTH;
|
||||
|
||||
// HTTP/3 specific options.
|
||||
uint64_t max_field_section_size = 0;
|
||||
// The maximum header section size advertised to the peer in SETTINGS.
|
||||
// Defaults to match max_header_length so the SETTINGS frame accurately
|
||||
// reflects the enforcement limit. A value of 0 would incorrectly tell
|
||||
// the peer not to send any headers at all.
|
||||
uint64_t max_field_section_size = DEFAULT_MAX_HEADER_LENGTH;
|
||||
uint64_t qpack_max_dtable_capacity = 4096;
|
||||
uint64_t qpack_encoder_max_dtable_capacity = 4096;
|
||||
uint64_t qpack_blocked_streams = 100;
|
||||
|
||||
Reference in new issue
Block a user