Commit e93b5dc0 authored by Yutaka Hirano's avatar Yutaka Hirano Committed by Commit Bot

Use FetchResponseType::kBasic in content::CreateFileURLLoader

The header comment is saying "this does not restrict filesystem access
*in any way*", so bypassing CORS is the expected behavior.

Bug: 1035575, 1036693,1026546
Change-Id: I1af6a25c9865d8c1f5f367db2ff277a9f5c101ac
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1980649Reviewed-by: default avatarTakashi Toyoshima <toyoshim@chromium.org>
Reviewed-by: default avatarMatt Falkenhagen <falken@chromium.org>
Commit-Queue: Yutaka Hirano <yhirano@chromium.org>
Auto-Submit: Yutaka Hirano <yhirano@chromium.org>
Cr-Commit-Position: refs/heads/master@{#727362}
parent 000ea683
......@@ -908,8 +908,8 @@ void CreateFileURLLoader(
FROM_HERE,
base::BindOnce(
&FileURLLoader::CreateAndStart, base::FilePath(), request,
CalculateResponseType(request.mode, /*is_allowed_access=*/false),
std::move(loader), std::move(client),
network::mojom::FetchResponseType::kBasic, std::move(loader),
std::move(client),
allow_directory_listing ? DirectoryLoadingPolicy::kRespondWithListing
: DirectoryLoadingPolicy::kFail,
FileAccessPolicy::kUnrestricted, LinkFollowingPolicy::kDoNotFollow,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment