| Index: chrome/browser/net/chrome_network_delegate.cc
|
| diff --git a/chrome/browser/net/chrome_network_delegate.cc b/chrome/browser/net/chrome_network_delegate.cc
|
| index 55eb0d92c882778756f6320830c2048f87a17bb3..b6215cf2ef0fd0c44049d1690f299a3d00e63f1e 100644
|
| --- a/chrome/browser/net/chrome_network_delegate.cc
|
| +++ b/chrome/browser/net/chrome_network_delegate.cc
|
| @@ -447,8 +447,10 @@ bool ChromeNetworkDelegate::OnCanSetCookie(const net::URLRequest& request,
|
| return allow;
|
| }
|
|
|
| -bool ChromeNetworkDelegate::OnCanAccessFile(const net::URLRequest& request,
|
| - const base::FilePath& path) const {
|
| +bool ChromeNetworkDelegate::OnCanAccessFile(
|
| + const net::URLRequest& request,
|
| + const base::FilePath& original_path,
|
| + const base::FilePath& absolute_path) const {
|
| #if defined(OS_CHROMEOS)
|
| // If we're running Chrome for ChromeOS on Linux, we want to allow file
|
| // access. This is checked here to make IsAccessAllowed() unit-testable.
|
| @@ -458,7 +460,14 @@ bool ChromeNetworkDelegate::OnCanAccessFile(const net::URLRequest& request,
|
| }
|
| #endif
|
|
|
| - return IsAccessAllowed(path, profile_path_);
|
| +#if defined(OS_ANDROID)
|
| + // Android's whitelist relies on symbolic links (ex. /sdcard is whitelisted
|
| + // and commonly a symbolic link), thus do not check absolute paths.
|
| + return IsAccessAllowed(original_path, profile_path_);
|
| +#else
|
| + return (IsAccessAllowed(original_path, profile_path_) &&
|
| + IsAccessAllowed(absolute_path, profile_path_));
|
| +#endif
|
| }
|
|
|
| // static
|
|
|