You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 6, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Nov 6, 2023. It is now read-only.
Use Ed25519 instead of RSA for ruleset signatures #12087
@Hainish By the way, I disagree with the entire approach of out-of-band updates for rulesets. See my comments in EFForg/privacybadger#1466 (comment) and following for Privacy Badger for why.
We use an airgapped signing machine, node is not installed on it.
For RSA signatures, the risk is prime factorization in a prime product modulus field.
For ECDSA, the risk is the Elliptic Curve Discrete Logarithm Problem.
The general consensus is that choosing two large prime factors for RSA (2048-bit for a prime product of a 4092-bit modulus) is more than enough to protect against a brute-force attack. For Quantum attacks like Shor's algorithm, RSA is more versatile. Yes, the key length is an issue, but only when that key is delivered in real-time in a TLS connection, when milliseconds matter. That's when Ec25519 is really preferred. We're bundling our RSA key with the extension - and bundling a 4092-bit key is trivial, it adds a mere 511 bytes to the filesize. This is not a real issue.
Besides, the real weak link in the development chain is that git is signing tags with sha1. So before I refer to the rest of the crypto team at EFF let's tackle the real problems. Using RSA for delivery of signed rulesets doesn't even come close.
The problem with crypto experts is there's about 3 of them in the world. This isn't a problem that requires a crypto expert, it's a problem that requires a third-party audit of a security firm.
@koops76 I agree this discussion isn't really productive anymore. I understand your points and disagree with some of them, and ultimately I agree with the EFF's library/algorithm decision here.
We don't need to invite more people to discuss this. We don't need to vote on this. The EFF staff have listened and disagree. If we can't trust them to make good security decisions then this entire project is in serious trouble, not just this one thing we're talking about.
Sorry @koops76 I hope you do not feel like you are being ignored.
My thoughts are that "RSA signatures are good enough", a debate about whether ed25519 is "more secure" than RSA is orthogonal to this. Even if ed25519 is more secure, RSA is still good enough.
Refactoring the signature scheme comes with some risk of its own, especially if it means adding a 3rd party dependency. I don't think this risk is worth it to improve a thing that is "good enough".
When will ed25519 be in webcrypto? If it is included there, it would be much easier and safer for us to use it.
Activity
jeremyn commentedon Aug 25, 2017
Where in the code do we use cryptographic signatures? I've tried to answer this question with some searches in GitHub, but couldn't.
jeremyn commentedon Aug 25, 2017
Thanks @koops76 .
@Hainish By the way, I disagree with the entire approach of out-of-band updates for rulesets. See my comments in EFForg/privacybadger#1466 (comment) and following for Privacy Badger for why.
Hainish commentedon Aug 25, 2017
@koops76 I'd rather use the WebCrypto API than some library, even if it has been publicly audited. The longevity of crypto APIs implemented directly in the browser seems better assured. We also need something which is supported by
openssl, given the signature scripts inutil:https://github.com/EFForg/https-everywhere/blob/sign-rulesets/utils/sign-rulesets-standalone.sh
https://github.com/EFForg/https-everywhere/blob/sign-rulesets/utils/sign-rulesets-request.sh
https://github.com/EFForg/https-everywhere/blob/sign-rulesets/utils/sign-rulesets-airgap.sh
ECDSA might work, and also has a shorter key size.
jeremyn commentedon Aug 25, 2017
In the gist https://gist.github.com/tqbf/be58d2d39690c3b366ad by the highly respected security expert Thomas Ptacek, under "Asymmetric signatures" he says
which supports @koops76 's point. On the other hand it's hard to argue with wanting to use the API included in the browser.
EDIT: he goes on to say
Hainish commentedon Aug 25, 2017
We use an airgapped signing machine, node is not installed on it.
For RSA signatures, the risk is prime factorization in a prime product modulus field.
For ECDSA, the risk is the Elliptic Curve Discrete Logarithm Problem.
The general consensus is that choosing two large prime factors for RSA (2048-bit for a prime product of a 4092-bit modulus) is more than enough to protect against a brute-force attack. For Quantum attacks like Shor's algorithm, RSA is more versatile. Yes, the key length is an issue, but only when that key is delivered in real-time in a TLS connection, when milliseconds matter. That's when Ec25519 is really preferred. We're bundling our RSA key with the extension - and bundling a 4092-bit key is trivial, it adds a mere 511 bytes to the filesize. This is not a real issue.
Besides, the real weak link in the development chain is that git is signing tags with sha1. So before I refer to the rest of the crypto team at EFF let's tackle the real problems. Using RSA for delivery of signed rulesets doesn't even come close.
Hainish commentedon Aug 25, 2017
The problem with crypto experts is there's about 3 of them in the world. This isn't a problem that requires a crypto expert, it's a problem that requires a third-party audit of a security firm.
29 remaining items
jeremyn commentedon Aug 29, 2017
@koops76 I agree this discussion isn't really productive anymore. I understand your points and disagree with some of them, and ultimately I agree with the EFF's library/algorithm decision here.
We don't need to invite more people to discuss this. We don't need to vote on this. The EFF staff have listened and disagree. If we can't trust them to make good security decisions then this entire project is in serious trouble, not just this one thing we're talking about.
jeremyn commentedon Aug 29, 2017
@koops76 I'm going to stop participating in this issue and let the EFF folks respond if they want to.
cowlicks commentedon Sep 14, 2017
re: #12087 (comment)
Sorry @koops76 I hope you do not feel like you are being ignored.
My thoughts are that "RSA signatures are good enough", a debate about whether ed25519 is "more secure" than RSA is orthogonal to this. Even if ed25519 is more secure, RSA is still good enough.
Refactoring the signature scheme comes with some risk of its own, especially if it means adding a 3rd party dependency. I don't think this risk is worth it to improve a thing that is "good enough".
When will ed25519 be in webcrypto? If it is included there, it would be much easier and safer for us to use it.