-
Notifications
You must be signed in to change notification settings - Fork 207
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CORS] Fixes Cors Headers Match Case Insensitive
Resolves #757 This solves two issues with CORS: Headers currently are not checking case-insensitive values for `Access-Control-Request-Headers`. Allowed headers should match against `Access-Control-Request-Headers` values. There was the belief that `response.flush` writes the contents of the response halting the request, this is not true, instead the request is continuing the pipeline. - Adds case insensitive check to `Access-Control-Request-Headers` - Validates that `Access-Control-Request-Headers` values match against ALLOWED_HEADERS - Adds invalid preflight specs. - Prevents call next for preflight requests With these changes in the event of preflight requests should respond to case insensitive preflight headers and the `call_next` should not be called.
- Loading branch information
Elias J. Perez
committed
Apr 17, 2018
1 parent
bea1063
commit 97a50e0
Showing
2 changed files
with
57 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters