Fetching a resource that contains a NUL byte in a header value using the fetch API does not result in an error in WebKit and even things such as HSTS work on such responses. Firefox and Chromium throw a network error for such cases. Example response: `strict-transport-security: max-age=20; in\u0000cludeSubDomains` Example URL: http://sub.headers.websec.saarland/_hp/tests/upgrade-hsts.sub.html?resp_type=parsing&browser_id=1&label=HSTS&first_id=32575&last_id=32575&scheme=http&t_resp_id=32575&t_element_relation=direct_direct&t_resp_origin=https://sub.headers.websec.saarland Seems to only be happening for `fetch`, img responses with \x00 in a header value seem to be blocked: https://bugs.webkit.org/show_bug.cgi?id=272739
<rdar://problem/126913166>
This seems to be restricted to no-cors case, where we do a sanitization in networking process, while we should check for nul headers in the response before.
Pull request: https://github.com/WebKit/WebKit/pull/27869
Submitted web-platform-tests pull request: https://github.com/web-platform-tests/wpt/pull/45980
Committed 278389@main (85f98322e6a6): <https://commits.webkit.org/278389@main> Reviewed commits have been landed. Closing PR #27869 and removing active labels.