Closed Bug 1632644 Opened 4 years ago Closed 4 years ago

PDF Viewer cannot launch a PDF attachment (but the pdf.js web app can)

Categories

(Firefox :: PDF Viewer, defect, P1)

75 Branch
defect

Tracking

()

VERIFIED FIXED
Firefox 78
Tracking Status
firefox-esr68 --- unaffected
firefox76 --- wontfix
firefox77 --- verified
firefox78 --- verified

People

(Reporter: jscher2000, Assigned: RyanVM)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0

Steps to reproduce:

Opened a PDF that contains an attachment that also is a PDF. For example: https://www.jeffersonscher.com/temp/Links-attachments-PDFs.pdf

The clicked the attached PDF to launch it in a new viewer.

Actual results:

PDF did not launch. Web Console displays:

Error: Access to 'blob:resource://pdf.js/d88abb45-ad65-447c-834b-d63f30884864?Amarin_COVID-19%20menu%20(01191490).PDF' from script denied
viewer.js:4510:14

Expected results:

The attached PDF should launch in a new tab in the PDF Viewer, similarly to what happens when you open the same PDF in the web app version of pdf.js at https://mozilla.github.io/pdf.js/web/viewer.html

Thread on SUMO: https://support.mozilla.org/questions/1285269

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → PDF Viewer

Mozregression:

2020-04-23T20:59:19.899000: DEBUG : Found commit message:
Bug 1615897 - Blob URL should not ignore query parameter and revokeObjectURL additionally should not ignore fragments. r=baku

Differential Revision: https://phabricator.services.mozilla.com/D63939

2020-04-23T20:59:19.899000: DEBUG : Did not find a branch, checking all integration branches


Accordingly, this is similar to bug 1628862 "Firefox 75 not loading PDF from BLOB, Security Error Content at...may not load data from blob:" filed on a different component

Regressed by: 1615897
Has Regression Range: --- → yes

The priority flag is not set for this bug.
:bdahl, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(bdahl)

Are you able to look into this regression?

Flags: needinfo?(bdahl) → needinfo?(evilpies)
Priority: -- → P1

Like bug 1628862 this uses a blob URL ending with a query: ?Amarin_COVID-19%20menu%20(01191490).PDF. That is not supposed to work per spec and as far as I can tell Chrome also implements it.

Flags: needinfo?(evilpies)

The severity field is not set for this bug.
:bdahl, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(bdahl)
Depends on: 1638364

This will be fixed in 78+ by way of bug 1638364. I'll look at creating a more targeted fix for Fx77 uplift too.

Status: UNCONFIRMED → NEW
Ever confirmed: true
Assignee: nobody → ryanvm
Status: NEW → ASSIGNED
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Flags: qe-verify+
Resolution: --- → FIXED
Target Milestone: --- → Firefox 78

Comment on attachment 9150538 [details]
Bug 1632644 - Allow PDF attachments to, once again, be opened directly in the browser. r=bdahl

Beta/Release Uplift Approval Request

  • User impact if declined: Some file attachments within PDFs will not work as expected.
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: See comment #1
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Should only affect pdfs with attachment files which are relatively rare.
  • String changes made/needed:
Flags: needinfo?(bdahl)
Attachment #9150538 - Flags: approval-mozilla-beta?

Comment on attachment 9150538 [details]
Bug 1632644 - Allow PDF attachments to, once again, be opened directly in the browser. r=bdahl

Approved for 77.0b9.

Attachment #9150538 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [qa-triaged]

I've reproduced the issue on Windows 10 and MacOS 10.15 using Firefox 78.0a1 (20200519160549)
Verified fixed on Firefox Nightly 78.0a1 (20200521093657) and Firefox Beta 77.0b9 (20200521224544)

Status: RESOLVED → VERIFIED
QA Whiteboard: [qa-triaged]
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: