Closed Bug 1655655 Opened 4 years ago Closed 4 years ago

Some MP4 Videos Still Fail to Play on Big Sur

Categories

(Core :: Security: Process Sandboxing, defect, P1)

80 Branch
Unspecified
macOS
defect

Tracking

()

VERIFIED FIXED
81 Branch
Tracking Status
firefox-esr68 --- wontfix
firefox-esr78 80+ verified
firefox78 --- wontfix
firefox79 --- wontfix
firefox80 --- verified
firefox81 --- verified

People

(Reporter: haik, Assigned: haik)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

On Nightly running on Big Sur Beta 3 (20A5323l), some MP4 videos fail to play and an error page is shown with "Video can't be played because the file is corrupt."

Example: https://external-preview.redd.it/mdSO1NO9awS309wHdSYqnZ1p-i55ccOJNtIZM4Fr8zg.gif?format=mp4&s=28e997c2da4ef358053b54017083b0b5b90fcbc0

The same video plays on Nightly on macOS 10.15.

Is there reason to believe that this is related to sandboxing again, similar to bug 1647816?

(In reply to Stephen A Pohl [:spohl] from comment #2)

Is there reason to believe that this is related to sandboxing again, similar to bug 1647816?

Yes, I can't reproduce it with the sandbox disabled so I'll recategorize this a sandbox issue.

Assignee: nobody → haftandilian
Component: Widget: Cocoa → Security: Process Sandboxing
Priority: -- → P1

The error appears to be caused by the call to VTDecompressionSessionCreate() in mozilla::AppleVTDecoder::InitializeSession() failing. The returned error is -12913: kVTVideoDecoderNotAvailableNowErr.

After adding access to the com.apple.trustd.agent service, the problem is not reproducible. From the trustd(8) man page "trustd provides services for evaluating trust in certificates for all processes on the system."

I tried using Console.app and the log command to get more information about the failure, but I haven't seen any error messages or TCC failures that might provide more information about why VTDecompressionSessionCreate() depends on the trustd.agent service. WebKit also allows this service in its WebProcess policy and it is allowed by App Store apps due to its inclusion in system.sb which is imported by application.sb on the macOS versions I checked (10.15 and 11.0 Beta 3).

Allow access to the "com.apple.trustd.agent" service in the content process sandbox. VTDecompressionSessionCreate() fails without it, causing playback failure for some MP4 videos.

Summary: Some MP4 Videos Fail to Play on Big Sur → Some MP4 Videos Still Fail to Play on Big Sur
Pushed by haftandilian@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/75724f5706ef
Some MP4 Videos Fail to Play on Big Sur r=spohl
See Also: → 1647816

I'll file an uplift request for Beta after the fix gets more testing on Nightly.

Flags: needinfo?(haftandilian)
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 81 Branch
Blocks: 1648487
Flags: needinfo?(haftandilian)

(In reply to Haik Aftandilian [:haik] from comment #0)

Example: https://external-preview.redd.it/mdSO1NO9awS309wHdSYqnZ1p-i55ccOJNtIZM4Fr8zg.gif?format=mp4&s=28e997c2da4ef358053b54017083b0b5b90fcbc0

Confirmed that this sample video now plays correctly since applying 81.0a1 (2020-07-30) update on Big Sur (10.16) Beta 3.

Should this video fix be uplifted to ESR 78? ESR 78 will be supported until mid-2022.

(In reply to Chris Peterson [:cpeterson] from comment #10)

Should this video fix be uplifted to ESR 78? ESR 78 will be supported until mid-2022.

Yes, we will need to uplift this to ESR 78 along with other Big Sur dependencies. We will be discussing the plan for ESR 68 and whether or not we need Big Sur fixes in the last ESR 68 release given the timing.

Comment on attachment 9166707 [details]
Bug 1655655 - Some MP4 Videos Fail to Play on Big Sur r?spohl!

ESR Uplift Approval Request

  • If this is not a sec:{high,crit} bug, please state case for ESR consideration: This fix is required for some videos to play on Firefox on the new macOS version (11.0 Big Sur) expected to release within the next few months.
  • User impact if declined: Without the fix, some MP4 videos will fail to play on Firefox 78 ESR on the new macOS version (11.0 Big Sur) expected to release within the next few months.
  • Fix Landed on Version: 81
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): The changes are Mac-specific. The changes touch some Mac sandboxing OS version checks and include a small sandbox rule change to allow a new service when running on macOS 11.0 Big Sur.
  • String or UUID changes made by this patch:

Beta/Release Uplift Approval Request

  • User impact if declined: Without the fix, some MP4 videos will fail to play on Firefox on the new macOS version (11.0 Big Sur) expected to release within the next few months.
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: Attempt to play the videos linked in comment 0 of this bug and bug 1647816 comment 9.
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): The changes are Mac-specific. The changes touch some Mac sandboxing OS version checks and include a small content process sandbox rule change to allow a new service when running on macOS 11.0 Big Sur.
  • String changes made/needed:
Attachment #9166707 - Flags: approval-mozilla-esr78?
Attachment #9166707 - Flags: approval-mozilla-beta?
Flags: qe-verify+
QA Whiteboard: [qa-triaged]

Comment on attachment 9166707 [details]
Bug 1655655 - Some MP4 Videos Fail to Play on Big Sur r?spohl!

compat for new macos version, approved for 80.0b4 and 78.2esr

Attachment #9166707 - Flags: approval-mozilla-esr78?
Attachment #9166707 - Flags: approval-mozilla-esr78+
Attachment #9166707 - Flags: approval-mozilla-beta?
Attachment #9166707 - Flags: approval-mozilla-beta+

Reproduced the issue on Firefox 79.0 (20200720193547)
Verified the fix on Firefox Beta 80.0b6 (20200807195315), Firefox Nightly 81.0a1 (20200810213634) and Firefox 78.2.0esr (20200806103136)

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: