[NativeFS] Allow access to files from MTP devices on Windows.
Introduces directories where access to the directory itself is blocked, and access to subdirectories is blocked as well, but individual files can still be opened. This enables opening of individual files stored on for example MTP devices on Windows, which is implemented on Windows by copying the file to a temporary directory and returning that path to chrome. This does not give access to folders on things like MTP devices. That will require a much larger rewrite/implementation of new file system backends, and is unlikely to happen anytime soon. But at least it won't result in the confusing "blocked because in a system folder" error if a user opens individual files on an MTP device (anything else is already filtered out/blocked by the file dialog itself, by the flags chrome passes to the file dialog). Also adds logging when we block access to a directory to make it easier to troubleshoot why certain paths are blocked, even if we can't reproduce it ourselves. Bug: 1094835 Change-Id: I170c3b9fa83c809d63d0a031aec5debd10bb3ff3 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2316888 Commit-Queue: Marijn Kruisselbrink <mek@chromium.org> Reviewed-by:Victor Costan <pwnall@chromium.org> Cr-Commit-Position: refs/heads/master@{#791513}
Showing
Please register or sign in to comment