News for hackers. Stuff that matters.
Re:Update Regarding Add-Ons in Firefox by JamesMcGill on Saturday May 04, 2019 @12:20PM (#19827379)
Hold up there. Before people start clicking and installing random add-on links, how about linking to something official (either from a FF dev, or in a soure repository) that references this URL?
Re:Update Regarding Add-Ons in Firefox by gpm on Saturday May 04, 2019 @12:23PM (#19827395)
So, I just got this url from this HN comment:

https://news.ycombinator.com/item?id=19825921

I'm not clear if they rehosted the XPI or if that's the original mozilla url.

I'm not too worried about it either. The only reason anyone is clicking on this fine link is because firefox only lets you install addons signed by Mozilla. And since the typical signing process gives addons signed by the broken intermediary we can be pretty confident that this wasn't just signed by mozilla, but is the original study.

In general caution about installing software from random links is definitely a good idea though.

Edit: Looks to me like it's an original mozilla url (judging by github comments on mozilla/normandy - I haven't found an official source saying it is official due to lack of continuing to search: https://github.com/mozilla/normandy/pull/1697)

Re:Update Regarding Add-Ons in Firefox by DoctorOetker on Saturday May 04, 2019 @08:08PM (#19830228)
>I'm not too worried about it either. The only reason anyone is clicking on this fine link is because firefox only lets you install addons signed by Mozilla.

unzip *.xpi

nano META-INF/manifest.mf

gives me

Manifest-Version: 1.0

Name: background.js Digest-Algorithms: MD5 SHA1 MD5-Digest: pcBRGwbuhPz06VrGWmAitQ== SHA1-Digest: szDd6YcB3bpF+NusZhEHhmMDi5U=

Name: content.js Digest-Algorithms: MD5 SHA1 MD5-Digest: CGOATrflEiq+QEu1IZlFvQ== SHA1-Digest: ps2bMGGRQdb4E7VOakqQEhJ8M5c=

Name: content.js.map Digest-Algorithms: MD5 SHA1 MD5-Digest: FY98a5hwQKH3g1fKcGK04A== SHA1-Digest: bAzZBP+YQ3EDWUXpqzKcTUw35Y0=

Name: manifest.json Digest-Algorithms: MD5 SHA1 MD5-Digest: eEm4sDKemttFN7G7JeLo0g== SHA1-Digest: 5W8OY1mk3QjECHzHna00iNXo9mM=

Name: experiments/skeleton/api.js Digest-Algorithms: MD5 SHA1 MD5-Digest: 0RBtD2TRmeE30v9+4TxXYA== SHA1-Digest: 2Uq9PO2H1iks/Cb7VAkfGrrD6hA=

Name: experiments/skeleton/schema.json Digest-Algorithms: MD5 SHA1 MD5-Digest: nSzuviuP+VtUvjE4IyIVhQ== SHA1-Digest: W311W+MXcHSsHIVFP15zxGUmQS8=

===

The hashes that certify the integrity of the files are under rigorous protection of ... MD5 and SHA1 (!)

Re:Update Regarding Add-Ons in Firefox by Dylan16807 on Saturday May 04, 2019 @10:27PM (#19830732)
What's your point?

There might be a very difficult preimage attack on MD5.

There's no evidence of a preimage attack on SHA1.

There is absolutely no way you're doing both at once.

Re:Update Regarding Add-Ons in Firefox by floatingatoll on Saturday May 04, 2019 @12:32PM (#19827461)
The blog post linked by this HN post is the official URL for the patch. Any installation method not described there is unofficial DIY, no matter how Mozilla-signed any given version of the XPI is.
Re:Update Regarding Add-Ons in Firefox by nine_k on Saturday May 04, 2019 @01:04PM (#19827708)
Sir, this is Hacker News.
Re:Update Regarding Add-Ons in Firefox by floatingatoll on Saturday May 04, 2019 @01:41PM (#19827934)
Yes, we are all quite advanced enough to footgun ourselves with abandon :) For everyone else, the fix is magically healing their browser without any intervention at all, and some of my high-skilled tech friends haven’t even noticed yet because they’re weekending and this all resolved itself before they realized it. Never underestimate the burden that being an “expert” places on your future time spend.
Re:Update Regarding Add-Ons in Firefox by human20190310 on Saturday May 04, 2019 @01:55PM (#19828033)
That hadn't occurred to me, but the fact that this is occurring on a weekend probably mitigates the impact to organizations that operate Monday-through-Friday.

Sucks for the Mozillans who are scrambling right now though. Hope they get a long weekend to compensate.

Re:Update Regarding Add-Ons in Firefox by floatingatoll on Saturday May 04, 2019 @02:09PM (#19828134)
I have to assume that’s why they focused on releasing a fix first and communicating second, because there was still hope to save everyone before the impact worsened. I hope they’re able to get at least a few hours of rest before Monday.
Re:Update Regarding Add-Ons in Firefox by toyg on Saturday May 04, 2019 @09:14PM (#19830477)
> Sucks for the Mozillans who are scrambling right now though.

I have little sympathy for people who ruined my own life - they push a fix and get feet up, while I'm left to reconfigure all my addons and containers for days.

Re:Update Regarding Add-Ons in Firefox by ChrisSD on Saturday May 04, 2019 @12:26PM (#19827415)
This is true. However it is signed by moz and looking at the source it seems safe enough (the cert is legit). It's just a normal wrapper with the following code added:

    // first inject the new cert
    try {
      let intermediate = "MIIHLTCCBRWgAwIBAgIDEAAIMA0GCSqGSIb3DQEBDAUAMH0xCzAJBgNVBAYTAlVTMRwwGgYDVQQKExNNb3ppbGxhIENvcnBvcmF0aW9uMS8wLQYDVQQLEyZNb3ppbGxhIEFNTyBQcm9kdWN0aW9uIFNpZ25pbmcgU2VydmljZTEfMB0GA1UEAxMWcm9vdC1jYS1wcm9kdWN0aW9uLWFtbzAeFw0xNTA0MDQwMDAwMDBaFw0yNTA0MDQwMDAwMDBaMIGnMQswCQYDVQQGEwJVUzEcMBoGA1UEChMTTW96aWxsYSBDb3Jwb3JhdGlvbjEvMC0GA1UECxMmTW96aWxsYSBBTU8gUHJvZHVjdGlvbiBTaWduaW5nIFNlcnZpY2UxJjAkBgNVBAMTHXNpZ25pbmdjYTEuYWRkb25zLm1vemlsbGEub3JnMSEwHwYJKoZIhvcNAQkBFhJmb3hzZWNAbW96aWxsYS5jb20wggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC/qluiiI+wO6qGA4vH7cHvWvXpdju9JnvbwnrbYmxhtUpfS68LbdjGGtv7RP6F1XhHT4MU3v4GuMulH0E4Wfalm8evsb3tBJRMJPICJX5UCLi6VJ6J2vipXSWBf8xbcOB+PY5Kk6L+EZiWaepiM23CdaZjNOJCAB6wFHlGe+zUk87whpLa7GrtrHjTb8u9TSS+mwjhvgfP8ILZrWhzb5H/ybgmD7jYaJGIDY/WDmq1gVe03fShxD09Ml1P7H38o5kbFLnbbqpqC6n8SfUI31MiJAXAN2e6rAOM8EmocAY0EC5KUooXKRsYvHzhwwHkwIbbe6QpTUlIqvw1MPlQPs7Zu/MBnVmyGTSqJxtYoklr0MaEXnJNY3g3FDf1R0Opp2/BEY9Vh3F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YMJCP8z0FIz3fv53FHgu3oeDhi2u3VdONjK3aaFWTlKNiGeDU0/lr0suWfQLsNyphTMbYKyTqQYHxXYJno9PuNi7e1903PvM47fKB5bFmSLyzB1hB1YIVLj0/YqD4nz3lADDB91gMBB7vR2h5bRjFqLOxuOutNNcNRnv7UPqtVCtLF2jVb4/AmdJU78jpfDs+BgY/t2bnGBVFBuwqS2Kult/2kth4YMrL5DrURIM8oXWVQRBKxzr843yDmHo8+2rqxLnZcmWoe8yQ41srZ4IB+V3w2TIAd4gxZAB0Xa6KfnR4D8RgE5sgmgQoK7Y/hdvd9Ahu0WEZI8Eg+mDeCeojWcyjF+dt6c2oERiTmFTIFUoojEjJwLyIqHKt+eApEYpF7imaWcumFN1jR+iUjE4ZSUoVxGtZ/Jdnkf8VVQMhiBA+i7r5PsfrHq+lqTTGOg+GzYx7OmoeJAT0zo4c=";
      let certDB = Cc["@mozilla.org/security/x509certdb;1"].getService(Ci.nsIX509CertDB);
      certDB.addCertFromBase64(intermediate, ",,");
      console.log("new intermediate certificate added");
    } catch (e) {
      console.error("failed to add new intermediate certificate:", e);
    }

    // Second, force a re-verify of signatures
    try {
      XPIDatabase.verifySignatures();
      console.log("signatures re-verified");
    } catch (e) {
      console.error("failed to re-verify signatures:", e);
    }
Re:Update Regarding Add-Ons in Firefox by lol768 on Saturday May 04, 2019 @12:30PM (#19827438)
Out of interest, what's special about this add-on that allows it to install intermediate certificates like this vs. an add-on that any random dev could write?
Re:Update Regarding Add-Ons in Firefox by ChrisSD on Saturday May 04, 2019 @12:37PM (#19827505)
In the manifest it has a special "experiment_apis":

    "experiment_apis": {
        "skeleton": {
            "schema": "experiments/skeleton/schema.json",
            "parent": {
                "scopes": [
                    "addon_parent"
                ],
                "script": "experiments/skeleton/api.js",
                "paths": [
                    [
                        "experiments",
                        "skeleton"
                    ]
                ]
            }
        }
    }
Only Mozilla can use these on release versions of Firefox. If you want some more details then try here: https://firefox-source-docs.mozilla.org/toolkit/components/e...
Re:Update Regarding Add-Ons in Firefox by denibertovic on Monday May 06, 2019 @09:12AM (#19839077)
Also how can I verify that intermediate certificate? Is that a base64 encoded string?
Re:Update Regarding Add-Ons in Firefox by denibertovic on Monday May 06, 2019 @09:11AM (#19839065)
Where does it say specifically on that page you linked that only Mozilla can use these apis?
Re:Update Regarding Add-Ons in Firefox by AsyncAwait on Saturday May 04, 2019 @12:34PM (#19827477)
It's installed as a study addon, only Mozilla could install these.
Re:Update Regarding Add-Ons in Firefox by lol768 on Saturday May 04, 2019 @12:37PM (#19827506)
> It's installed as a study addon, only Mozilla could install these.

And that gives it access to use `Cc`/Components.classes?

Re:Update Regarding Add-Ons in Firefox by AsyncAwait on Saturday May 04, 2019 @01:21PM (#19827817)
Not familiar with the specifics, just know that Mozilla uses this mechanism to sometimes ship experimental features to a select group of Firefox users that have it enabled and they used it today to issue this hotfix to anyone who has field studies enabled.
Re:Update Regarding Add-Ons in Firefox by ogurechny on Saturday May 04, 2019 @05:32PM (#19829519)
Why can't they just release that certificate for everyone to install on all affected non-recent and derivative builds (like Tor Browser)? Or is the internal certificate storage different from the one that is configurable in settings? Then tell us straight away what file to change, and the community (everyone likes to mention so much) comes up with the ways to patch it much faster than you think.
Re:Update Regarding Add-Ons in Firefox by noisem4ker on Saturday May 04, 2019 @06:49PM (#19829884)
Thanks to this script, I think I just managed to apply the patch to an old Firefox 56 install, whereas the .xpi had no effect.
Re:Update Regarding Add-Ons in Firefox by gpm on Saturday May 04, 2019 @10:25PM (#19830726)
There are other people here who I think would really appreciate details if you still have them.
Re:Update Regarding Add-Ons in Firefox by elebor on Sunday May 05, 2019 @02:31AM (#19831483)