Signature warnings on extensions

Board for discussions around the Basilisk web browser.

Moderator: satrow

GMforker
Astronaut
Astronaut
Posts: 537
Joined: Thu, 27 Aug 2015, 06:29
Location: Czech Republic

Re: Signature warnings on extensions

Unread postby GMforker » Sat, 06 Jan 2018, 08:12

ianas wrote:this is relativly new as I don't remember these warnings a few days ago

See #238.

ianas wrote:disabling then re-enabling the affected addons does not help

You must uninstall and reinstall (not disabling and re-enabling). For Basilisk < 2017.12.28 (from the source code < 2017.12.19).

This patch needs to be improved upon - according to the logic already mentioned above.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 08:19

What does this have to do with the discussion at hand because what you quoted and what you linked has no clear connection.

GMforker
Astronaut
Astronaut
Posts: 537
Joined: Thu, 27 Aug 2015, 06:29
Location: Czech Republic

Re: Signature warnings on extensions

Unread postby GMforker » Sat, 06 Jan 2018, 08:31

IMHO - STR:

Basilisk < 2017.12.28 (2017.12.18-):
- Create a new profile
- Install unsigned extension (Press the button "Restart now")
- This warning will not appear

Basilisk >= 2017.12.28 (e.g. 2018.01.05):
- Create a new profile
- Install unsigned extension (Press the button "Restart now")
- This warning appears

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 08:40

Ok.. I still don't know the relevance of this to the issue of Signed Add-ons with Invalidated Signatures being allowed to install.

Are you saying you compromised that validation when you "fixed" an issue relating to id-less webextensions being blocked from installation? Does this have to do with unsigned extensions having warnings? What. If you did do something that compromised invalid signatures being blocked then it must be reversed at once. When it comes down to it.. Proper application extensions trump webextensions every time and signature verification and trust must trump everything.

Please, for crying out loud, use words in sentences that explain things in detail. This is serious.
Last edited by New Tobin Paradigm on Sat, 06 Jan 2018, 09:06, edited 8 times in total.

GMforker
Astronaut
Astronaut
Posts: 537
Joined: Thu, 27 Aug 2015, 06:29
Location: Czech Republic

Re: Signature warnings on extensions

Unread postby GMforker » Sat, 06 Jan 2018, 09:41

Unfortunatelly, I do not understand. What should be the goal of any change?

Again, all three variants (+ settings):

xpinstall.signatures.required = false (default)

Basilisk (before #238):

An addon - unsigned:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

An addon - signed - but this signature is invalid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

An addon - signed - this signature is valid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

xpinstall.signatures.required = true

Basilisk (before #238):

An addon - unsigned:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear


An addon - signed - but this signature is invalid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear


An addon - signed - this signature is valid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

xpinstall.signatures.required = false (default)

Basilisk (after #238 - i.e. 2018.01.05):

An addon - unsigned:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") appears

An addon - signed - but this signature is invalid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") appears

An addon - signed - this signature is valid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

xpinstall.signatures.required = true

Basilisk (after #238 - i.e. 2018.01.05):

An addon - unsigned:
- It cannot be installed ("This add-on could not be installed because it has not been verified.")
/ - This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") appears ?

An addon - signed - but this signature is invalid:
- It cannot be installed ("This add-on could not be installed because it appears to be corrupt.")
/ - This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") appears ?

An addon - signed - this signature is valid:
- It's going to install
- This warning ("[addon name] could not be verified for use in [application]. Proceed with caution.") will not appear

---

If you see a bug somewhere... Please edit it according to your preferences. IMHO: The red text is important (at least I don't see a bug there - the green text is considered).
But that it was unintentional for #238...
Last edited by GMforker on Sat, 06 Jan 2018, 10:11, edited 6 times in total.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 10:02

"The warning above" Above what? What warning? The "X is not verified for use in Y" warning in the add-ons manager OR the Doorhanger error about it being corrupt (which in Tycho shows for edited signed extensions).

USE SENTENCES THAT EXPLAIN THINGS IN DETAIL. Language barriers aside.. Do you not know how to speak like a person?

I can't read this crap with green and red and highlights.. Also, what does that pref have to do with anything.. Whatever that preference is set to by default should be your testing criteria.. Anyway.. I am going to test this personally because I need to KNOW and you are not telling me.
Last edited by New Tobin Paradigm on Sat, 06 Jan 2018, 10:04, edited 3 times in total.

GMforker
Astronaut
Astronaut
Posts: 537
Joined: Thu, 27 Aug 2015, 06:29
Location: Czech Republic

Re: Signature warnings on extensions

Unread postby GMforker » Sat, 06 Jan 2018, 10:20

The text (warning) added to the post.

New Tobin Paradigm wrote:Do you not know how to speak like a person?

No. I'm a robot (probably). Artificial Intelligence. I'm sorry, Artificial Non-Intelligence, of course.

New Tobin Paradigm wrote:I can't read this crap with green and red and highlights...

So now I really do not know what else to do...

New Tobin Paradigm wrote:Anyway.. I am going to test this personally

Yes, that's best.
Last edited by GMforker on Sat, 06 Jan 2018, 10:21, edited 2 times in total.

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1509
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Signature warnings on extensions

Unread postby JustOff » Sat, 06 Jan 2018, 11:57

New Tobin Paradigm wrote:Yeah, it WILL check for signatures and like Pale Moon it SHOULD verify signatures if existent. [..]

Obviously, the best solution is to reinstate and fix the behavior to match what we have now on Pale Moon. No signature should install (if not strictly enforcing -- which we don't enable) and Signature should be checked for validity and integrity if it exists. If it is not valid it should be rejected and installation blocked and if somehow slid in by some means should be disabled.

I'm not sure you are right about how Pale Moon handles signed extensions. Currently it treats all signatures from Mozilla as "invalid because the certificate used to sign this file has an unrecognized issuer", but allows to install regardless of this verification error. And although I have never seen any extensions signed not by Mozilla in the wild, I doubt that Pale Moon would refuse to install such add-ons even if the signature is broken.
Last edited by JustOff on Sat, 06 Jan 2018, 12:24, edited 1 time in total.
Here are the add-ons I made in a spare time. That was fun!

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 12:34

Assuming you are correct.. This is totally the wrong behavior.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 16:07

So here is the latest.

Pale Moon 26 and below would validate extension signatures according to str8 up CAs in the certificate store. However if the issuer was not known it would allow install of extensions in a valid or tampered with state regardless.

  • Signed Known Issuer (Valid XPI) - Allow Install
  • Signed Known Issuer (Tampered with XPI) - Block install (Add-on is corrupt)
  • Signed Unknown Issuer (Valid and Tampered with XPI) - Allow install

Pale Moon 27 and UXP will ONLY validate extension signatures against a hard coded implementation of AMO's Certificate Authority and ONLY when Add-on Signing is enforced from compile time. Otherwise it is treated as Signed Unknown Issuer as above.

It is noteworthy to add that when Mozilla first started signing Add-ons on AMO for extensions in Pale Moon 26 and older we had to remove the signatures for edits and forks or else get that "add-on is corrupted" error. I do know that Mozilla signed their entire datastore twice. I can only assume the second time was to resign them to match this hardcoded c++ implimented CA that Pale Moon 27 and UXP (and everything at Mozilla) uses now.

What we are likely going to have to for UXP (this kind of complex work likely won't be duplicated/backported to Pale Moon 27) will be the following:

  • Rewrite how Add-on Signing is handed to simplify it and return checking to the certificate store
  • Figure out exactly what to do about the hard coded AMO CA either get it to check it first then check against the certificate store or get it to spit out something and import it into the certificate store.

This work is going to take a while to accomplish so for now be mindful that Extension Signature Validation Signing is busted.

As for GMForker, your implementation in UXP PR #238 was completely the wrong approach and had implications all over the place. It should be backed out.

Stay tuned...
Last edited by New Tobin Paradigm on Sat, 06 Jan 2018, 16:13, edited 2 times in total.

GMforker
Astronaut
Astronaut
Posts: 537
Joined: Thu, 27 Aug 2015, 06:29
Location: Czech Republic

Re: Signature warnings on extensions

Unread postby GMforker » Sat, 06 Jan 2018, 17:13

New Tobin Paradigm wrote:ONLY when Add-on Signing is enforced from compile time

So the user can not choose enforce and do not enforce signatures...

At least please you delete the "xpinstall.signatures.required" option, if it makes no sense (and it did not work right from the start).

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 17:16

As a platform.. It would be important to keep the preference. Also, if you bothered reading anything I said before you blind-sighted me with your thing.. I said there is a difference between allowing unsigned add-ons and what should be done with those that ARE signed..

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 4625
Joined: Tue, 09 Oct 2012, 19:37

Re: Signature warnings on extensions

Unread postby New Tobin Paradigm » Sat, 06 Jan 2018, 20:39

I feel it is necessary to iterate something just in case anyone is thinking bad things might happen and come out of this thread and the exploration into the issue..

Pale Moon and Basilisk have zero plans to enforce any kind of strict signing or restrict unsigned add-ons.. Nor will the Add-ons Site be involved in signing extensions on behalf of Add-on Developers. This whole thing is to find out what is going on with the source code and resolve issues for add-ons that ARE signed but whose integrity is not being properly checked. Not so much for AMO.. That ship is sailing on May 8th. Though, a lot of people are still going to have Mozilla Signed add-ons for a long time.

Please see my previous post where I discuss the difference between allowing unsigned add-ons and what should be done with those that are signed that makes the comparison with http/https.

If you have any further questions please pose them.. I will do my best to answer.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 22140
Joined: Sun, 28 Aug 2011, 17:27
Location: 58.5°N 15.5°E
Contact:

Re: Signature warnings on extensions

Unread postby Moonchild » Tue, 09 Jan 2018, 00:21

For the record, Mozilla broke add-on signing in the "normal" way when they changed from reliance on NSS to a built-in certDB with only Mozilla certificates. Ever since then, invalidly-signed extensions (including tampered ones) are tossed on the heap "unsigned" because from Mozilla's perspective, that is all that mattered (signed = signed by Mozilla). I opened a bug for this incorrect behavior but was unheard. This was back in the Firefox 34-38 era; so yes it's been broken for a long time.

Since "unsigned" is perfectly fine for us, I'll remove the warning thrown when an "unsigned" (meaning either unsigned or invalid or modified or non-mozilla signed) extension is found when not required (by pref). The pref will still work and block (for the time being, anyway) and should be read as "require Mozilla signing".
Improving Mozilla code: You know you're on the right track with code changes when you spend the majority of your time deleting code.

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne

User avatar
SpockFan02
Lunatic
Lunatic
Posts: 459
Joined: Sun, 24 Sep 2017, 16:35

Re: Signature warnings on extensions

Unread postby SpockFan02 » Tue, 09 Jan 2018, 02:54

Will this mean no more Author not verified? Or, is that different from signing?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 22140
Joined: Sun, 28 Aug 2011, 17:27
Location: 58.5°N 15.5°E
Contact:

Re: Signature warnings on extensions

Unread postby Moonchild » Tue, 09 Jan 2018, 08:39

SpockMan02 wrote:Will this mean no more Author not verified? Or, is that different from signing?

It's all related.
Improving Mozilla code: You know you're on the right track with code changes when you spend the majority of your time deleting code.

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1509
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Signature warnings on extensions

Unread postby JustOff » Tue, 09 Jan 2018, 15:06

Moonchild wrote:Mozilla broke add-on signing in the "normal" way

This is not entirely true, see the comment on Issue #277.
Here are the add-ons I made in a spare time. That was fun!

coffeebreak
Board Warrior
Board Warrior
Posts: 1362
Joined: Sat, 26 Sep 2015, 04:51
Location: U.S.

Re: Signature warnings on extensions

Unread postby coffeebreak » Sat, 03 Feb 2018, 18:13

With release of Basilisk-2018-02-02, the issue of warnings for unsigned (or signed-but-edited) add-ons appears solved.

installing such add-ons no longer produces a warning in the add-ons manager.

For any add-ons that already had these warnings, reinstalling them made the warning disappear.

User avatar
gracious1
Keeps coming back
Keeps coming back
Posts: 836
Joined: Sun, 15 May 2016, 05:00
Location: muggy, muggy upstate NY

Re: Signature warnings on extensions

Unread postby gracious1 » Tue, 06 Feb 2018, 17:51

coffeebreak wrote:With release of Basilisk-2018-02-02, the issue of warnings for unsigned (or signed-but-edited) add-ons appears solved. For any add-ons that already had these warnings, reinstalling them made the warning disappear.

In my case, I didn't even have to re-install. I just switched the value extensions.blocklist.enabled back to true, and everything was hunky-dory! Thanks for fixing this! :thumbup:
Image“We look forward to the time when the Power of Love will replace the Love of Power. Then will our world know the blessings of peace.” ― Wm. Ewart Gladstone ◊ Int'l Day of Peace 21 Sept. ◊


Return to “Basilisk”

Who is online

Users browsing this forum: yami_ and 1 guest