Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(25)

Issue 190533005: Bug 343571: Dragging and dropping a directory containing a symlink results in the symlink being ign…

Created:
6 years, 9 months ago by eocanha
Modified:
6 years, 9 months ago
Reviewers:
kinuko, Tom Sepez, jschuh, tzik
CC:
chromium-reviews, kinuko+watch, darin-cc_chromium.org, dcheng, nhiroki, tzik
Base URL:
https://chromium.googlesource.com/chromium/src.git@344225
Visibility:
Public.

Description

Bug 343571: Dragging and dropping a directory containing a symlink results in the symlink being ignored. DraggedFileUtil inherits some of its operations from LocalFileUtil and its LocalFileEnumerator, both performing checks to avoid following symbolic links for security reasons (as it should be for generic local files). However, files coming from a drag & drop operation can be considered "trusted files" (after all, the user is who is dropping them there on purpose) and should honor symbolic links. This patch modifies DraggedFileUtil to override that behaviour, acting as LocalFileUtil does, but without skipping symbolic links. To achieve this, a new FollowSymlinksLocalFileEnumerator is defined, which also does the same as LocalFileEnumerator but without the checks. BUG=343571

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+85 lines, -6 lines) Patch
M webkit/browser/fileapi/dragged_file_util.h View 1 chunk +6 lines, -0 lines 0 comments Download
M webkit/browser/fileapi/dragged_file_util.cc View 4 chunks +79 lines, -6 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
eocanha
6 years, 9 months ago (2014-03-07 21:48:31 UTC) #1
kinuko
not lgtm. We skip symlinks intentionally (crbug.com/229849) to avoid potential security risks (e.g. a dragged ...
6 years, 9 months ago (2014-03-10 02:33:05 UTC) #2
eocanha
On 2014/03/10 02:33:05, kinuko wrote: > not lgtm. I understand that, as owner, you have ...
6 years, 9 months ago (2014-03-10 17:22:17 UTC) #3
kinuko
(+jschuh@) I'm not the best person to judge the security implication here, let me add ...
6 years, 9 months ago (2014-03-11 03:56:06 UTC) #4
jschuh
The root problem here is that the sandbox architecture and ChildProcessSecurityPolicy base their security decisions ...
6 years, 9 months ago (2014-03-11 21:26:16 UTC) #5
Tom Sepez
I agree with Justin and kinuko in that the assumptions are sprinkled throughout chrome, and ...
6 years, 9 months ago (2014-03-13 18:34:18 UTC) #6
eocanha
6 years, 9 months ago (2014-03-13 19:01:02 UTC) #7
On 2014/03/13 18:34:18, Tom Sepez wrote:
> I agree with Justin and kinuko in that the assumptions are sprinkled
throughout
> chrome, and we're better off without this.

Thank you all for having had a look at this. Now I understand the full
consequences of enabling symbolic links.

I've left a comment in the bug explaining the situation. It would be great if
somebody could mark the bug as WONTFIX (I don't have permission).

Powered by Google App Engine
This is Rietveld 408576698