microsoft / microsoft/react-native-windows
Switch from denylist to allowlist for headers that should be appended with validation in NetworkingModule
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 17.3k
- Forks
- 1.2k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 33
Description
Proposal: Switch from denylist to allowlist for headers that should be appended with validation in NetworkingModule
Summary
We currently validate all HTTP headers other than "Authorization" and there is a PR to skip validation of "User-Agent". In the PR, @acoates-ms proposed that we switch from explicitly listing the headers that should skip validation to instead explicitly list the headers that should be validated.
See https://github.com/microsoft/react-native-windows/pull/8392 for more details.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in NetworkingModule and read the details in pull request 8392 and its linked discussion. Change the header-validation decision from an explicit denylist to an explicit allowlist, preserving the intended handling of Authorization and User-Agent; done means the module validates only the headers listed by the new policy.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, react-native
- Domain
- networking
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100