commit | f04938e02551c56a0363fca50d49fe97b0c9098f | [log] [tgz] |
---|---|---|
author | Ryo Ogawa <negibokken@gmail.com> | Thu Feb 03 03:41:27 2022 |
committer | Chromium LUCI CQ <chromium-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu Feb 03 03:41:27 2022 |
tree | 1d576390adf288a2fc16cf6733935faaa85fbddb | |
parent | 82b0d78ea9e52e234484ccad4a22a65e1344fdb1 [diff] |
Fix parsing algorithm for Access Control Expose Headers (ACEH) This CL fixes the implementation for parsing ACEH values to pass the two failed WPT. ``` { "input": "Access-Control-Expose-Headers:\r\nAccess-Control-Expose-Headers: bb-8", "exposed": true }, { "input": "Access-Control-Expose-Headers: ,bb-8", "exposed": true }, ``` According to the Fetch Standard [1], the first test case is interpreted as below and it's the same as the second test case. ``` Access-Control-Expose-Headers: ,bb-8", ``` The Fetch Standard says the parsing ACEH algorithm follows the RFC 7230 [2]. And in RFC 7230, the empty element must be accepted and ignored for legacy list rules [3]. > For compatibility with legacy list rules, a recipient MUST parse and > ignore a reasonable number of empty list elements [1] https://fetch.spec.whatwg.org/#example-header-list-get-decode-split [2] https://fetch.spec.whatwg.org/#concept-response-cors-exposed-header-name-list [3] https://datatracker.ietf.org/doc/html/rfc7230#section-7 Bug: 978146 Change-Id: Ic7a379c4bb0189299d0d64156173c3cc02a80323 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3422206 Reviewed-by: Takashi Toyoshima <toyoshim@chromium.org> Commit-Queue: Takashi Toyoshima <toyoshim@chromium.org> Cr-Commit-Position: refs/heads/main@{#966572}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone
! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.