refactor the algorithm for testing the cors

while here:
- send cors headers even if the status is 404
- add: access_control_expose_headers config option - list of additional headers sent in Access-Control-Expose-Headers
- add: access_control_allow_credentials config option - if true return Access-Control-Allow-Credentials header equal "true"
This commit is contained in:
tomasz.sowa committed 2022-09-08 03:12:44 +02:00
1 parent 04164ff967
commit 222a1c8a1f
9 files changed
+245 -89

No files matched your search

+2
View File
@@ -353,6 +353,8 @@ void Config::AssignValues()
allow_all_cors_origins = Bool(L"allow_all_cors_origins", false);
ListText(L"allowed_cors_origins", allowed_cors_origins);
ListText(L"access_control_expose_headers", access_control_expose_headers);
access_control_allow_credentials = Bool(L"access_control_allow_credentials", false);
}