http2: expand list of known headers
This PR adds access-control-*, dnt, forwarded, tk, upgrade-insecure-requests, warning, x-content-type-options and x-frame-options to known list of headers for HTTP2. Also expands tests to account for these headers. Should address https://github.com/nodejs/node/issues/15337
All of the headers added have an official proposal/standard and are in active use. There might be more that I missed since they're kind of scattered all over and there's no one perfect list.
The most impactful thing here is the validation for new single value headers (since adding things that aren't single value headers to that list would break users' code):
- access-control-allow-credentials
- access-control-max-age
- access-control-request-method
- dnt
-
forwardedUpdate: this is clearly not single value (this is just a list error here, the code doesn't make the same mistake) - tk
- upgrade-insecure-requests
- x-content-type-options
Let me know if any changes are needed. Thanks!
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
commit message follows commit guidelines
Affected core subsystem(s)
http2, test