No Save as on AMO since 1.9.9.98rc1

Ask for help about NoScript, no registration needed to post
Mc

No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Since version 1.9.9.98rc1 I must whitelist addons.mozilla.org to get the context menu with "Save as" to save a xpi file. I suppose it comes from the "Surrogate to use InstallTrigger on AMO even if addons.mozilla.org is not
whitelisted"
I don't want to whitelist amo generally, because there are some issues using SeaMonkey. Finally I deleted the about:config entry for noscript.surrogate.amo.sources. Seems that helped.
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
User avatar
Giorgio Maone
Site Admin
Posts: 9524
Joined: Wed Mar 18, 2009 11:22 pm
Location: Palermo - Italy
Contact:

Re: No Save as on AMO since 1.9.9.98rc1

Post by Giorgio Maone »

That surrogate is quite important because prevents subverted mirrors or MITM attacks from installing rogue versions of AMO-hosted add-ons.
In order to get back the "Save as..." functionality (which is subject to the aforementioned vulnerability, though), you can just change the noscript.surrogate.amo.replacement preference to

Code: Select all

addEventListener('click',function(e){if(e.button) return;a=e.target.parentNode;var hash=a.getAttribute('data-hash');if(hash){var b=a.parentNode.parentNode;InstallTrigger.install({x:{URL:a.href,IconURL:b.getAttribute('data-icon'),Hash:hash,toString:function(){return a.href}}});e.preventDefault()}},false)
This will be made the default in next release.
Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6
Mc

Re: No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Giorgio Maone wrote:In order to get back the "Save as..." functionality (which is subject to the aforementioned vulnerability, though), you can just change the noscript.surrogate.amo.replacement preference...
Thanks Giorgio, I've reset noscript.surrogate.amo.sources, made the change and it works.
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
User avatar
therube
Ambassador
Posts: 7969
Joined: Thu Mar 19, 2009 4:17 pm
Location: Maryland USA

Re: No Save as on AMO since 1.9.9.98rc1

Post by therube »

If you have FlashGot installed, you can Alt+Click the link, capturing the wanted download file.

Hmm. Is that actually accomplishing anything, or is that still going to be "subject to the aforementioned vulnerability"?

So you're say the only way to avoid 'MITM' is to either use the existing noscript.surrogate.amo.replacement or to Allow addons.mozilla.org?
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball NoScript FlashGot AdblockPlus
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:2.0b2pre) Gecko/20100630 SeaMonkey/2.1a3pre
User avatar
Giorgio Maone
Site Admin
Posts: 9524
Joined: Wed Mar 18, 2009 11:22 pm
Location: Palermo - Italy
Contact:

Re: No Save as on AMO since 1.9.9.98rc1

Post by Giorgio Maone »

therube wrote:So you're say the only way to avoid 'MITM' is to either use the existing noscript.surrogate.amo.replacement or to Allow addons.mozilla.org?
Yes, and always use the left click install (no "save as" or download), because AMO's files are served from non-HTTPS "release.mozilla.org" mirrors.
Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6
Mc

Re: No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Giorgio Maone wrote:Yes, and always use the left click install (no "save as" or download), because AMO's files are served from non-HTTPS "release.mozilla.org" mirrors.
I'm modifying Firefox and Thunderbird extensions for my use in SeaMonkey, what needs downloads. If I understand you right, that's not save at all.
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
Mc

Re: No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Mc wrote:
Giorgio Maone wrote:Yes, and always use the left click install (no "save as" or download), because AMO's files are served from non-HTTPS "release.mozilla.org" mirrors.
I'm modifying Firefox and Thunderbird extensions for my use in SeaMonkey, what needs downloads. If I understand you right, that's not save at all.
...save is not safe :-P
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
Mc

Re: No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Fixed with 1.9.9.98rc4.
But still the question: "Save as" not safe on AMO?
Is there a way to get it safe with NoScript? Or why is download/install safe and download/save not?
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
User avatar
Giorgio Maone
Site Admin
Posts: 9524
Joined: Wed Mar 18, 2009 11:22 pm
Location: Palermo - Italy
Contact:

Re: No Save as on AMO since 1.9.9.98rc1

Post by Giorgio Maone »

Mc wrote:But still the question: "Save as" not safe on AMO?
The add-ons files are served from a random releases.mozilla.org mirror over HTTP (unsecured).
Therefore, especially if you're using a proxy, a public Wi-Fi hotspot or an internet provider which you can't trust, a malicious file can be served instead through a MITM attack.
Mc wrote:Is there a way to get it safe with NoScript?
Nope. NoScript already does its best at ensuring you get the correct file, by forcing InstallTrigger to work even if scripts are disabled.
Mc wrote:Or why is download/install safe and download/save not?
Because install is carried on by the InstallTrigger function, which compares a cryptographic hash of the file provided by the install page (over secured HTTPS) with the one computed by the browser after the unsafe download has been completed over HTTP: if the two hashes don't match, you've got a tampered file and the installation fails.
Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6
Mc

Re: No Save as on AMO since 1.9.9.98rc1

Post by Mc »

Thanks Giorgio for your explanations.
So finally I suppose I'm rather safe, because I use the proxy of my trustworthy provider.
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.10) Gecko/20100504 Mnenhy/0.8.3 SeaMonkey/2.0.5
dhouwn
Bug Buster
Posts: 968
Joined: Thu Mar 19, 2009 12:51 pm

Re: No Save as on AMO since 1.9.9.98rc1

Post by dhouwn »

Giorgio Maone wrote:Therefore, especially if you're using a proxy, a public Wi-Fi hotspot or an internet provider which you can't trust, a malicious file can be served instead through a MITM attack.
And you should also care when reading Giorgio's posts over an unsecured line, as a malicious text might be served instead.
Note: Giorgio will never ask you for your passwords in a forum post.

SCNR
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.4) Gecko/20100611 Firefox/3.6.4
Post Reply