-
-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider making ECDSA (p-256) the default certificate type #2350
Comments
thanks. I will think about it. |
Awesome, thanks. A lot of projects (such as Caddy) will continue to renew certs with the existing key type, and then switch over new certificates to ECDSA. Either way, thank you so much for your consideration! |
don't know if it is well supported to use ed25519 but using a key type which uses a broken number generator feels wrong for me. |
@c33s The baseline requirements do not permit any publicly trusted CA to issue end entity certificates with an ed25519 public key at this time. Only RSA and ECDSA (with a specific set of curves, namely NIST P-256, P-384, or P-521). |
@cpu It's unlikely that browsers will support ed25519 (for authentication) in certificates any time soon (see for instance https://community.letsencrypt.org/t/can-should-isrg-submit-a-proposal-to-support-ed25519-ed448-certificates-to-ca-b-forum/85127/5 ), but many browsers and servers do support X25519 and X448 (for key exchange), instead of the NIST curves. |
It would be really cool, with two caveats:
in the meantime, we could introduce an |
支持ECDSA |
@DuckFine PRs welcome :) |
P-256 = secp256r1 = prime256v1 is not safe, why not use ed25519 or secp256k1 ? |
P-256 is safe, and neither of your two options are currently allowed for use in publicly trusted certificates. |
Certificate curves and ECDH key exchange curves are both used at the same time, don't mix them up. You can only (currently) have a P-256 or a P-384 certificate (also 512, but not on Let's Encrypt), which only certifies you control the domain name, and at the same time you can use whatever curve you want (browser support permitting) for an Elliptic-curve Diffie–Hellman key exchange. The actual data is encrypted with an ephemeral key (AES 128 or 256 usually). |
As far as I know, "ed25519" cert is not supported by CAB yet. And |
Hey Neil, for this to work well, we need to be able to use -k ec-foo with --renew, but at present that is not possible, |
Certbot is switching to ecdsa with the next big upgrade |
@Neilpang, can acme.sh reconsider this, too? (for new certificates, not for renewals) |
yes, we will make this change soon. |
CA uses auth SHA384; will cause most of the openvpn to fail, which is really a headache |
That's a CA/B requirement when using a p384 intermediate. If the CA uses a p256 intermediate it must then use sha256 in signatures. If it uses an RSA intermediate, then it can use sha256 (and others, I think). |
|
Hi @Neilpang, Just for reference, Certbot 2.0 now issues ECC (P-256) certificates by default (for new certificates, renewal of existing RSA certificates not impacted), see https://github.com/certbot/certbot/releases/tag/v2.0.0. You may want to wait a bit to see how that goes, but then make the switch for acme.sh as well? |
Nice, then this is closed. Took a decade |
Hi, this broke my Unifi deployment as soon as I started issuing certs from a new clone of acme.sh, because the Unifi-OS web application only supports RSA certificates. It was necessary to delete the domain directory that had been created under |
If you want RSA 4096 bits, it's fine. But don't. You have two perfectly fine shorter lengths.
(nb: acme.sh supporting it doesn't mean the CA will support it) |
Is it possible to revert the default certificate type to RSA due compatibility issues? |
I'm a bit confused. I can see acme.sh started issuing ECC certs by default which is fine to me. But |
Add "--ecc" parameter |
Thanks for the tip. But this was pretty unexpected - I suppose I'd expect the defaults between commands to be consistent. If acme.sh is now renewing and "managing" an ECC cert by default and has abandoned my RSA cert - for it to do the same at installation time too :-/ I worked around earlier by archiving/renaming the old stale RSA folders which I suppose is roughly equivalent since they are all expiring shortly anyway. |
If you have both rsa and ecdsa certs issued, that's the only way to distinguish them. If you have only ecdsa cert, acmesh can select the correct cert automatically. |
|
Just one more reason to not use separate directories. Just one more thing that causes confusion and breaks behaviors that existed for half a decade. On the basis of "just cause". For issuance you don't ask for And this wouldn't be a problem, if you used the same dir you've been using for years. Why does the install command need to know the cert's algo, seriously? Give me one reason. Just one. It should be completely irrelevant to the issue command, it's not an encryption tool, it's a copy tool. It shouldn't care less about the key algo. The directory name should be fixed. The directory belongs to domains, not algos. All this fuss because you refuse to admit a bad design decision. Instead, you just double down. |
Sorry for the confusions. but if you read the readme carefully, you will know that the internal folder structure is not reliable. And you will also know that the Then, if you folllow the usage of Acctaully I don't know why you have to care about the folder structure. It was never recommended to use the files in the internal positions. Imagine that if you use a hidden/undocumented api of Windows, then Windows updates , the api breaks. That's not Windows' fault. For the I knew that the change for default key type is not a small change, but I had made everything possible to keep 99% compabible. And I can guarantee that if one follows the public command line parameters, his acme.sh would not break. The world is changing all the time, it's not a static world. We have to move on. Sorry for the confustion again. if you have any more problems, I'd be happy to help you and all. |
I personally don't think this makes much sense. If I was OK with default RSA certs earlier, using I understand that if there are multiple certs (e.g RSA and ECC) to use for If it helps, here's the story
I think this could be simpler with a different default selection. Happy to raise a separate issue/request if you think it might be useful. |
That would also cause compaible issues. There are many existing users have both Usually there is no 100% perfect solution while upgrading. It's just a choose between A and B.
Yes, we can improve the logs or output or our docs about it. If any one has good advices, I'm all ears. Thanks |
I checked the manual several times already. It makes no mention of
I don't want any of this to happen.
Precisely because there's either a) no option to just copy the certs and not do anything else on the system b) your readme is wrong.
This, to me, still makes no sense, regardless of whether I should touch files under But like I said, feel free to call it whatever you want, as long as you either give me a flag (or update the readme about such flag) that copies the cert to a second folder, and does absolutely nothing else. |
It's your choice to evaluate, but personally I would consider the "principle of least astonishment" and that would be sensible defaults that are consistent with one another across commands. Since changing the default key type is still a breaking change for everyone previously using default RSA and Treating some commands differently to others with respect to defaults is just going to cause more confusion over time, I feel. |
Well, now you got it. I will update the readme soon. And maybe I will rename the command to OK, To anyone who reads this post in future: never, never ,never use the files directly in the internal folder Anyone can also contibute to the readme.md files too. |
If you issued RSA cert before, the cert will be renewed without any breaks. |
You cut off the important part of the sentence with the "and".
I explained above exactly how it's a breaking change when combining defaults with |
As you are running acme.sh master branch code in production, you should expect changes from time to time... The P-256 default is not in any acme.sh release yet. |
Yes, fair enough, I understand. However to be extra fair that is the suggested install approach, It also doesn't look like the official release is going to be any different in 'breakingneas' of behaviour anyway based on the above, so discovery on master may be a moot point. And if it is different than current master, it'll likely be because folks on the edge tried out master and provided feedback. |
when will it be possible to use ed25519 and ed448? |
That's a question for the CA/B Forum. |
Even if CA/B forum didn't forbid their issuance, it wouldn't matter much as browsers do not yet support EdDSA as a signature scheme for digital certificates anyways. |
I understood. They could be released for us to use with other applications. I, for example, have been using ed25519 for a long time with openvpn generating my self-signed certificates with easy-rsa |
I think we will support Ed algorithms when the ACME protocol supports them. |
on page 12 of rfc8555 it says that it should be implemented: https://datatracker.ietf.org/doc/html/rfc8555#section-6.2 "An ACME server MUST implement the “ES256” signature algorithm [RFC7518] and SHOULD implement the “EdDSA” signature algorithm using the “Ed25519” variant (indicated by “crv”) [RFC8037]." Today I was looking at the bind9 log and even the dnssec zones already support it: named[10861]: DNSSEC algorithms: RSASHA1 NSEC3RSASHA1 RSASHA256 RSASHA512 ECDSAP256SHA256 ECDSAP384SHA384 ED25519 ED448 I understand that browsers don't support it, but we could generate our certificates with the --eddsa or --ed25519 parameter to use in other services, for example dns-over-tls and dns-over-https. In addition to being more secure, it is faster and uses less server processing. |
That's for JWS and JWS alone. Not for TLS. But don't worry too much. CA/B will eventually decide to support EdDSA, you just have to wait for the Chrome and/or Firefox teams start pushing it. It will only work with the newest versions, tho. And ecdsa p-256 is small enough already. |
I'm not sure if this is the ideal place to post this, but I just wanted to give people a heads-up that Mozilla's future "Server Side TLS" guidelines will recommend ECDSA certificates for the Intermediate configuration level. This is one of the most commonly used TLS configurations for servers across the internet.
mozilla/server-side-tls#178
mozilla/server-side-tls#254
https://ssl-config.mozilla.org/
In our research, we found that ECDSA and RSA certificates were equally compatible with the vast majority of clients across the internet, comprising this set of clients:
The reason why we are recommending ECDSA certificates over RSA certificates is that they give IE11 clients on Windows 7 access to ECDHE for key exchange; with RSA they are limited to classic DHE. My apologies if this project already uses ECDSA by default.
Please let me know if you have any questions! Thanks!
The text was updated successfully, but these errors were encountered: