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

Issue 197033005: Ignore suggested download filename for cross origin links. (Closed)

Created:
6 years, 9 months ago by asanka
Modified:
6 years, 7 months ago
Reviewers:
adamk, abarth-chromium
CC:
blink-reviews, dglazkov+blink, adamk+blink_chromium.org
Visibility:
Public.

Description

Ignore suggested download filename for cross origin links. The @download attribute can be used to propose a filename for a download. If the download was initiated by a different, potentially untrusted origin, then using the proposed filename from the @download attribute can be a security concern. Therefore, only expose the proposed filename after verifying that the request isn't a cross origin request. The request can still be redirected to a different origin. Therefore the embedder is responsible for ignoring the suggested name on a cross origin redirect. The companion CL https://codereview.chromium.org/246893006/ implements this for //content. Depends on Chromium CL: https://codereview.chromium.org/200663002/ for test_runner changes. BUG=346744 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=172767

Patch Set 1 #

Total comments: 2

Patch Set 2 : Revive #

Messages

Total messages: 12 (0 generated)
asanka
adamk: Could you take a look?
6 years, 9 months ago (2014-03-14 19:27:36 UTC) #1
adamk
Seems reasonable to me, but I'd be interested in looking at the bug; could you ...
6 years, 9 months ago (2014-03-14 20:39:42 UTC) #2
asanka
On 2014/03/14 20:39:42, adamk wrote: > Seems reasonable to me, but I'd be interested in ...
6 years, 9 months ago (2014-03-14 20:50:51 UTC) #3
adamk
lgtm, but I'd like abarth to look at this change before it gets committed.
6 years, 9 months ago (2014-03-14 21:37:57 UTC) #4
asanka
On 2014/03/14 21:37:57, adamk wrote: > lgtm, but I'd like abarth to look at this ...
6 years, 9 months ago (2014-03-14 22:37:11 UTC) #5
abarth-chromium
not lgtm https://codereview.chromium.org/197033005/diff/1/Source/core/html/HTMLAnchorElement.cpp File Source/core/html/HTMLAnchorElement.cpp (right): https://codereview.chromium.org/197033005/diff/1/Source/core/html/HTMLAnchorElement.cpp#newcode437 Source/core/html/HTMLAnchorElement.cpp:437: frame->loader().client()->loadURLExternally(request, NavigationPolicyDownload, suggestedName); This check doesn't work. ...
6 years, 9 months ago (2014-03-17 18:17:48 UTC) #6
asanka
https://codereview.chromium.org/197033005/diff/1/Source/core/html/HTMLAnchorElement.cpp File Source/core/html/HTMLAnchorElement.cpp (right): https://codereview.chromium.org/197033005/diff/1/Source/core/html/HTMLAnchorElement.cpp#newcode437 Source/core/html/HTMLAnchorElement.cpp:437: frame->loader().client()->loadURLExternally(request, NavigationPolicyDownload, suggestedName); On 2014/03/17 18:17:48, abarth wrote: > ...
6 years, 9 months ago (2014-03-17 18:50:24 UTC) #7
asanka
Adam and Adam: I've revived this CL by splitting the responsibility of dealing with cross ...
6 years, 8 months ago (2014-04-23 19:05:03 UTC) #8
abarth-chromium
lgtm
6 years, 8 months ago (2014-04-23 20:15:31 UTC) #9
asanka
The CQ bit was checked by asanka@chromium.org
6 years, 7 months ago (2014-04-28 14:19:12 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/asanka@chromium.org/197033005/20001
6 years, 7 months ago (2014-04-28 14:19:26 UTC) #11
commit-bot: I haz the power
6 years, 7 months ago (2014-04-28 15:28:14 UTC) #12
Message was sent while issue was closed.
Change committed as 172767

Powered by Google App Engine
This is Rietveld 408576698