bugzilla.mozilla.org has resumed normal operation. Attachments prior to 2014 will be unavailable for a few days. This is tracked in Bug 1475801.
Please report any other irregularities here.

On Linux, System extensions fail to load in local builds run outside of ./mach

RESOLVED FIXED in Firefox 57

Status

WebExtensions
Request Handling
P1
normal
RESOLVED FIXED
a year ago
27 days ago

People

(Reporter: haik, Assigned: haik)

Tracking

(Blocks: 1 bug)

56 Branch
mozilla57
Unspecified
Linux

Firefox Tracking Flags

(firefox57 fixed)

Details

MozReview Requests

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(2 attachments)

(Assignee)

Description

a year ago
When starting a developer unpackaged local build on Linux, (e.g., running ./firefox) system extensions will encounter errors when loading resources. For example, the screenshot extension fails when 

As a workaround, set MOZ_DEVELOPER_REPO_DIR to be the path to the repo. As in

  $ MOZ_DEVELOPER_REPO_DIR=/path/to/my/mozilla-central/ ./obj/dist/bin/firefox

This problem occurs because ExtensionProtocolHandler only allows unpacked extensions to load resources outside of their extension directory if the resource resides within the repo dir. The repo dir is obtained from MOZ_DEVELOPER_REPO_DIR, but that isn't always set when Firefox is run. I'm working on a fix for this that doesn't depend on MOZ_DEVELOPER_REPO_DIR.
(Assignee)

Updated

a year ago
Assignee: nobody → haftandilian
(Assignee)

Updated

a year ago
Blocks: 1386460
(Assignee)

Updated

a year ago
Priority: -- → P1
Comment hidden (mozreview-request)
Comment hidden (mozreview-request)
(Assignee)

Comment 3

11 months ago
The posted patches 1) fix the problem when firefox is run outside of ./mach without the MOZ_DEVELOPER_REPO_DIR environment variable being set and 2) make ExtensionProtocolHandler not depend on MOZ_DEVELOPER_REPO_DIR ever being set.

When the dev build security check exception was added, I expected we would always require MOZ_DEVELOPER_REPO_DIR to be set on Linux. In the end, our Linux sandboxing implementation didn't require MOZ_DEVELOPER_REPO_DIR due to how it resolves symlinks. On the Mac, the sandboxing implementation does require knowing the full path to the repo, but it is obtained from the Info.plist file, not an environment variable.
Comment hidden (mozreview-request)
Comment hidden (mozreview-request)

Comment 6

11 months ago
mozreview-review
Comment on attachment 8894968 [details]
Bug 1386832 - Part 1 - Move non-sandbox-specific routines out of SandboxSettings.

https://reviewboard.mozilla.org/r/164994/#review171846
Attachment #8894968 - Flags: review?(jmathies) → review+

Comment 7

11 months ago
mozreview-review
Comment on attachment 8894969 [details]
Bug 1386832 - Part 2 - Make Linux dev build security check exception not depend on MOZ_DEVELOPER_REPO.

https://reviewboard.mozilla.org/r/166078/#review171852
Attachment #8894969 - Flags: review?(jmathies) → review+
Comment hidden (mozreview-request)
Comment hidden (mozreview-request)

Comment 10

11 months ago
Pushed by haftandilian@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/2779bfca2a01
Part 1 - Move non-sandbox-specific routines out of SandboxSettings. r=jimm
https://hg.mozilla.org/integration/autoland/rev/86b17cf120ca
Part 2 - Make Linux dev build security check exception not depend on MOZ_DEVELOPER_REPO. r=jimm

Comment 11

11 months ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/2779bfca2a01
https://hg.mozilla.org/mozilla-central/rev/86b17cf120ca
Status: NEW → RESOLVED
Last Resolved: 11 months ago
status-firefox57: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla57

Updated

27 days ago
Product: Toolkit → WebExtensions
You need to log in before you can comment on or make changes to this bug.