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

Issue 2098263002: [Offline Page]Making mhtml file recognized as openable by Chrome (Closed)

Created:
4 years, 5 months ago by Vivian
Modified:
4 years, 4 months ago
Reviewers:
Ted C, palmer, fgorski, dewittj
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@tryout
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Offline Page]Making mhtml file recognized as openable by Chrome. There are several scenarios that user want to open an mhtml file of offline page: from third party apps when user receive the file as attachment, from Android’s download home, and from file manager apps. The third party apps that offline page sharing feature intended to make use of are Gmail, ShareIt, Xender, Beam and Drive. Each of these schemes differs in the intent sent out when trying to open the mhtml file. This CL made changes on the intent filters so that Chrome would be known to the system as a handler of mhtml VIEW intent in different schemes. First filter only declares mimeType, enables intent that keeps the mimeType "multipart/related" (Beam,Drive,Download, File Manager). Second filter declares the pathPatter, enables intent that lost the mimeType but keeps the ".mhtml" postfix (Xender). The last filter added [mimeType=”*/*”], enables ShareIt open the file. Deleting either of the intent filter will cause at least one scheme not working properly. Drive and Download use content uri, which is not considered as local url. In MHTMLArchive::create, mhtml pages from non-local URLs are blocked for security reasons. As a result, content won't show properly. Related discussion can be seen in bug 630753. BUG=622139 Committed: https://crrev.com/6d63d246b893f5033749391030e8a36172356c3a Cr-Commit-Position: refs/heads/master@{#408242}

Patch Set 1 #

Patch Set 2 : Enable open with mimetype and extension #

Patch Set 3 : Enable open file from ShareIt #

Total comments: 6

Patch Set 4 : Add support to mht and eml #

Total comments: 8

Patch Set 5 : Make schemes explicit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+28 lines, -1 line) Patch
M chrome/android/java/AndroidManifest.xml View 1 2 3 4 1 chunk +28 lines, -1 line 0 comments Download

Depends on Patchset:

Messages

Total messages: 34 (16 generated)
Vivian
ptal
4 years, 5 months ago (2016-07-25 20:00:09 UTC) #4
dewittj
https://codereview.chromium.org/2098263002/diff/40001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/40001/chrome/android/java/AndroidManifest.xml#newcode193 chrome/android/java/AndroidManifest.xml:193: <intent-filter> nit: I don't think this file should have ...
4 years, 5 months ago (2016-07-25 20:13:26 UTC) #5
Vivian
https://codereview.chromium.org/2098263002/diff/40001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/40001/chrome/android/java/AndroidManifest.xml#newcode193 chrome/android/java/AndroidManifest.xml:193: <intent-filter> On 2016/07/25 20:13:26, dewittj wrote: > nit: I ...
4 years, 5 months ago (2016-07-25 21:51:44 UTC) #6
fgorski
lgtm on my end, Ted, could you help us, by either reviewing or routing to ...
4 years, 4 months ago (2016-07-26 16:46:12 UTC) #9
Ted C
Adding palmer@ from security (please reroute if someone is a better assignee for this!). No ...
4 years, 4 months ago (2016-07-26 17:01:48 UTC) #11
Vivian
https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml#newcode190 chrome/android/java/AndroidManifest.xml:190: <category android:name="android.intent.category.DEFAULT" /> On 2016/07/26 17:01:47, Ted C wrote: ...
4 years, 4 months ago (2016-07-26 17:12:59 UTC) #12
Ted C
https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml#newcode191 chrome/android/java/AndroidManifest.xml:191: <data android:mimeType="multipart/related"/> On 2016/07/26 17:12:59, Vivian wrote: > On ...
4 years, 4 months ago (2016-07-26 17:17:09 UTC) #13
Vivian
https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml#newcode191 chrome/android/java/AndroidManifest.xml:191: <data android:mimeType="multipart/related"/> On 2016/07/26 17:17:09, Ted C wrote: > ...
4 years, 4 months ago (2016-07-26 17:21:37 UTC) #14
Ted C
https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml#newcode191 chrome/android/java/AndroidManifest.xml:191: <data android:mimeType="multipart/related"/> On 2016/07/26 17:21:37, Vivian wrote: > On ...
4 years, 4 months ago (2016-07-26 17:24:02 UTC) #15
dewittj
On 2016/07/26 17:24:02, Ted C wrote: > Ah, didn't know that. Not sure whether it ...
4 years, 4 months ago (2016-07-26 17:26:06 UTC) #16
Vivian
https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml File chrome/android/java/AndroidManifest.xml (right): https://codereview.chromium.org/2098263002/diff/60001/chrome/android/java/AndroidManifest.xml#newcode191 chrome/android/java/AndroidManifest.xml:191: <data android:mimeType="multipart/related"/> On 2016/07/26 17:24:02, Ted C wrote: > ...
4 years, 4 months ago (2016-07-26 17:41:31 UTC) #17
dewittj
lgtm
4 years, 4 months ago (2016-07-26 22:46:45 UTC) #18
palmer
I've pinged the security team. Will get back to you ASAP.
4 years, 4 months ago (2016-07-27 19:27:13 UTC) #19
palmer
OK, LGTM. Thanks!
4 years, 4 months ago (2016-07-27 20:35:44 UTC) #20
Ted C
lgtm (rubber stamp)
4 years, 4 months ago (2016-07-27 21:27:06 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2098263002/80001
4 years, 4 months ago (2016-07-27 21:27:40 UTC) #28
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 4 months ago (2016-07-27 21:31:02 UTC) #30
commit-bot: I haz the power
4 years, 4 months ago (2016-07-27 21:32:30 UTC) #32
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/6d63d246b893f5033749391030e8a36172356c3a
Cr-Commit-Position: refs/heads/master@{#408242}

Powered by Google App Engine
This is Rietveld 408576698