-
Notifications
You must be signed in to change notification settings - Fork 30k
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
http: join all duplicate headers #45982
http: join all duplicate headers #45982
Conversation
Review requested:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm -1 on adding a CLI flag. This changes behavior of existing code in a potentially sensitive way, and users do not necessarily know which parts of their application require current behavior or not.
I think the suggestion from the ticket is actually way better (and as I'm spelling this out, I realize it's your own suggestion 🙂), which is to add a flag to the HTTP server/client options instead.
@addaleax yes it was my suggestion to use the option in server/client 😄. While working on it I realized it was very messy and produced unexpected behavior (the option missing from server but present in the client) so I switched to a flag which seemed to me a cleaner and "universal" solution. |
@marco-ippolito How does using a CLI flag solve that? Typically, client and server won't be running in the same process or be even developed/deployed by the same person, so you'll end up with a good chance of mismatches for this option either way. |
This should be an option, not a CLI flag. |
ok changing it to option. Should I mark it as experimental in the docs? |
Actually, RFC 9110 requires multiple occurrences of all comma-separated headers to be joinable. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Blocking and requesting changes because the documentation is wrong.
See: #46240. |
Notable changes: * crypto: * (SEMVER-MINOR) add CryptoKey Symbol.toStringTag (Filip Skokan) [#46042](#46042) * (SEMVER-MINOR) add KeyObject Symbol.toStringTag (Filip Skokan) [#46043](#46043) * http: * (SEMVER-MINOR) join authorization headers (Marco Ippolito) [#45982](#45982) * lib: * add webstreams to Duplex.from() (Debadree Chatterjee) [#46190](#46190) * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) [#46205](#46205) PR-URL: TBD
Notable changes: * crypto: * (SEMVER-MINOR) add CryptoKey Symbol.toStringTag (Filip Skokan) [#46042](#46042) * (SEMVER-MINOR) add KeyObject Symbol.toStringTag (Filip Skokan) [#46043](#46043) * http: * (SEMVER-MINOR) join authorization headers (Marco Ippolito) [#45982](#45982) * lib: * add webstreams to Duplex.from() (Debadree Chatterjee) [#46190](#46190) * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) [#46205](#46205) PR-URL: #46286
Notable changes: * http: * (SEMVER-MINOR) join authorization headers (Marco Ippolito) [#45982](#45982) * lib: * add webstreams to Duplex.from() (Debadree Chatterjee) [#46190](#46190) * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) [#46205](#46205) PR-URL: #46286 Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
Notable changes: * http: * (SEMVER-MINOR) join authorization headers (Marco Ippolito) [#45982](#45982) * lib: * add webstreams to Duplex.from() (Debadree Chatterjee) [#46190](#46190) * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) [#46205](#46205) PR-URL: #46286 Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
Notable changes: * http: * (SEMVER-MINOR) join authorization headers (Marco Ippolito) [#45982](#45982) * lib: * add webstreams to Duplex.from() (Debadree Chatterjee) [#46190](#46190) * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) [#46205](#46205) PR-URL: #46286 Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
Notable changes: * deps: * upgrade npm to 9.3.1 (npm team) #46242 * doc: * add parallelism note to os.cpus() (Colin Ihrig) #45895 * http: * join authorization headers (Marco Ippolito) #45982 * improved timeout defaults handling (Paolo Insogna) #45778 * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) #46205 PR-URL: #46396
Notable changes: * deps: * upgrade npm to 9.3.1 (npm team) #46242 * doc: * add parallelism note to os.cpus() (Colin Ihrig) #45895 * http: * join authorization headers (Marco Ippolito) #45982 * improved timeout defaults handling (Paolo Insogna) #45778 * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) #46205 PR-URL: #46396
Notable changes: * deps: * upgrade npm to 9.3.1 (npm team) #46242 * doc: * add parallelism note to os.cpus() (Colin Ihrig) #45895 * http: * join authorization headers (Marco Ippolito) #45982 * improved timeout defaults handling (Paolo Insogna) #45778 * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) #46205 PR-URL: #46396
Notable changes: * deps: * upgrade npm to 9.3.1 (npm team) #46242 * doc: * add parallelism note to os.cpus() (Colin Ihrig) #45895 * http: * join authorization headers (Marco Ippolito) #45982 * improved timeout defaults handling (Paolo Insogna) #45778 * stream: * implement finished() for ReadableStream and WritableStream (Debadree Chatterjee) #46205 PR-URL: #46396
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: nodejs#45982
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: #45982 PR-URL: #48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: #45982 PR-URL: #48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: nodejs#45982 PR-URL: nodejs#48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: nodejs#45982 PR-URL: nodejs#48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: #45982 PR-URL: #48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: #45982 PR-URL: #48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Null the `joinDuplicateHeaders` property when the parser is freed. Refs: #45982 PR-URL: #48608 Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
resolves: #45699
I have introduced a new option named
joinDuplicateHeaders
inhttp.request
andhttp.createServer
to allow joining multiple headers instead of discarding the ones after the first as described by rfc 9110