Closed Bug 541420 Opened 14 years ago Closed 14 years ago

Files extracted from XPI files have their executableness stripped

Categories

(Toolkit :: Add-ons Manager, defect)

defect
Not set
normal

Tracking

()

VERIFIED FIXED
mozilla1.9.3a1
Tracking Status
blocking1.9.2 --- -
status1.9.2 --- .9-fixed
status1.9.1 --- unaffected

People

(Reporter: mossop, Assigned: mossop)

References

Details

(Keywords: regression)

Attachments

(2 files)

The tweaks we made to the extraction process in bug 526598 made us more forceful about ensuring the file permissions were correct but this has the side effect of removing any executable bit from the file permissions. We need to make sure at least the read/write permissions are there preserving the executable permissions.
Keywords: regression
Attached patch patch rev 1Splinter Review
Took a while to get a unit test that did a decent check on all platforms but I think this is it. The test zip file includes a file called "binary" that was marked executable before compressing, it should extract as executable as well.

The fix just ensures we apply at least the file access bits we need at a minimum and allows any executable bits to pass through as well.
Attachment #423116 - Flags: review?(robert.bugzilla)
Comment on attachment 423116 [details] [diff] [review]
patch rev 1

Might be good to expand the comment to state that our code doesn't understand NTFS file permissions. Hopefully one day we will get that implemented.
Attachment #423116 - Flags: review?(robert.bugzilla) → review+
Landed on trunk: http://hg.mozilla.org/mozilla-central/rev/bee5caea0941, will look for branch approval shortly.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a1
Depends on: 542387
Depends on: 542466
No longer depends on: 542466
Backed this out while I figure out what is up with the test failures.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Relanded with an additional line of logging to try to narrow down where the problem is. The logging shouldn't affect most users and I'll remove it after a short period of time.

http://hg.mozilla.org/mozilla-central/rev/5ad17deecfe0
Status: REOPENED → RESOLVED
Closed: 14 years ago14 years ago
Resolution: --- → FIXED
blocking1.9.2: ? → needed
Where are we at with this?
(In reply to comment #6)
> Where are we at with this?

We have an intermittent test failure I can neither reproduce or understand which leaves me unable to be sure of how safe this is to take on branch. It appears that the failure hasn't happened in over a month though.
Ready for a branch landing yet?
Comment on attachment 423116 [details] [diff] [review]
patch rev 1

Yeah lets take this on branch, the intermittent failures appear to have gone away, I can't see any way that they could have been a code problem.
Attachment #423116 - Flags: approval1.9.2.5?
Comment on attachment 423116 [details] [diff] [review]
patch rev 1

Approved for 1.9.2.5, a=dveditz for release-drivers
Attachment #423116 - Flags: approval1.9.2.5? → approval1.9.2.5+
Attached file Test extension
the test extension attached doesnt seem to verify the fix against 1.9.2.5.   reopening.   It does however, work against trunk nightly.

Tested against on Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.7pre) Gecko/20100701 Namoroka/3.6.7pre
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
oops.  this should status = verified fixed on trunk, and then i reset flags of blocking1.9.2 =? and status1.9.2 = ?.   Please correct if i missed something.
Status: REOPENED → RESOLVED
blocking1.9.2: needed → ?
Closed: 14 years ago14 years ago
Resolution: --- → FIXED
and verified fix on Minefield trunk:

Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:2.0b2pre) Gecko/20100701 Minefield/4.0b2pre.
Status: RESOLVED → VERIFIED
Comment on attachment 423116 [details] [diff] [review]
patch rev 1

a-LegNeato for 1.9.2.8.
Attachment #423116 - Flags: approval1.9.2.5+ → approval1.9.2.8+
blocking1.9.2: ? → -
Landed on the branch: http://hg.mozilla.org/releases/mozilla-1.9.2/rev/df760e6d4ddc
Looks like the right one this time too!
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: