Closed Bug 323826 Opened 20 years ago Closed 20 years ago

Uninstall of an extension that contains a windows .lnk fails (in some cases breaking all operations)

Categories

(Toolkit :: Add-ons Manager, defect)

1.8.0 Branch
x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: robert.strong.bugs, Assigned: robert.strong.bugs)

References

Details

(Keywords: fixed1.8.0.4, fixed1.8.1)

Attachments

(2 files, 1 obsolete file)

Turns out that an extension was distributed that contains a xulrunner.lnk file that is zero bytes in size. I am sure that it was just an oversight by the extension author and this is an edgecase but it is an edgecase we should not fail on. Patch coming up.
Attachment #208795 - Flags: review?(benjamin)
Comment on attachment 208795 [details] [diff] [review] patch (don't follow symbolic links) I'm going to look into this a little bit more... it turns out the install failed for me when the xpi contained a .lnk so I am not yet sure how this situation occured in the first place. The bug demonstrated by the files that were sent to me is fixed by the patch but it may need a bit more bullet proofing.
Attachment #208795 - Flags: review?(benjamin)
Attachment #208817 - Flags: review?(benjamin)
Attachment #208817 - Flags: review?(benjamin) → review+
Fixed on trunk new revision: 1.167; previous revision: 1.166
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Attachment #208817 - Flags: branch-1.8.1+
Fixed on MOZILLA_1_8_BRANCH for Firefox 2.0
Keywords: fixed1.8.1
*** Bug 318760 has been marked as a duplicate of this bug. ***
Comment on attachment 208817 [details] [diff] [review] patch (never follow symbolic links returned from EM getDir functions) Requesting 1.8.0.2 - this is an edgecase but all we need to break the Extension Manager for a lot of users is for one popular extension to be distributed with a zero byte .lnk file in it. The only way for the user to recover is to manually delete the extension's directory when this occurs without this patch.
Attachment #208817 - Flags: approval1.8.0.2?
Comment on attachment 208817 [details] [diff] [review] patch (never follow symbolic links returned from EM getDir functions) as per discussion in triage meeting 23-feb-2006
Attachment #208817 - Flags: approval1.8.0.3?
Attachment #208817 - Flags: approval1.8.0.2?
Attachment #208817 - Flags: approval1.8.0.2-
Flags: blocking1.8.0.3?
Comment on attachment 208817 [details] [diff] [review] patch (never follow symbolic links returned from EM getDir functions) Hmm... setting followLinks to false has no effect on Linux. Will this bug still occur on Linux with a malformed symlink?
iirc this bug doesn't occur on Linux. I'll verify if / when I have the time if someone doesn't beat me to it.
Flags: blocking1.8.0.3? → blocking1.8.0.3+
Comment on attachment 208817 [details] [diff] [review] patch (never follow symbolic links returned from EM getDir functions) approved for 1.8.0 branch, a=dveditz for drivers
Attachment #208817 - Flags: approval1.8.0.3? → approval1.8.0.3+
(In reply to comment #7) > Requesting 1.8.0.2 - this is an edgecase but all we need to break the > Extension Manager for a lot of users Could you elaborate? It sounds like you're saying it's worse than "can't uninstall this one extension". What does QA need to test?
It can break extension installs, upgrades, and uninstalls for an extension. In thinking on it, I believe the original reporter had installed the extension with 1.0 which didn't have this problem and then upgraded. At that point there is no way to install, upgrade, or uninstall the extension except by manually removing it from the file system. Once this breakage occurs, the extension manager can end up in a state where additional operations will fail due to it trying to complete an operation - usually an uninstall - on the extension that contains a zero byte .lnk file. I'll attach a testcase shortly
Attached file xpi testcase
A test xpi that contains a zero byte .lnk file which can't be uninstalled or upgraded with 1.5.0.x
Summary: Uninstall of an extension that contains a windows .lnk fails → Uninstall of an extension that contains a windows .lnk fails (in some cases breaking all operations)
Checked in to MOZILLA_1_8_0_BRANCH Checking in mozilla/toolkit/mozapps/extensions/src/nsExtensionManager.js.in; /cvsroot/mozilla/toolkit/mozapps/extensions/src/nsExtensionManager.js.in,v <-- nsExtensionManager.js.in new revision: 1.144.2.16.2.4; previous revision: 1.144.2.16.2.3
Keywords: fixed1.8.0.3
Product: Firefox → Toolkit
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: