-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add ECDSA support #2443
base: staging
Are you sure you want to change the base?
Add ECDSA support #2443
Conversation
I have not looked into it at all. What about TLSA? I |
Damn... yes. Didn't think about that yet because I don't use DNSSEC. But that makes migration from an RSA-only setup indeed more complex for users that are already using DNSSEC. Any ideas how to solve that easily?
|
And that’s where hacky starts and delivery may fail. |
That means we need a configuration option where users explicitly have to turn on ECDSA. I was hoping to avoid that (we have enough such options already), but there is no way around it. I guess we could turn it on by default on new installs though (from generate_config.sh). |
Can we get docs for this? :) |
Sure! :-) If the PR is ready to get merged and the functionality is more or less complete, then I'll add something about it to the documentation. |
Looks complete. :) Do you think this is ready to be merged? A few words in the docs are enough. |
I've added a few words about it to documentation and I updated the chapter slightly. I hope it's all right. :-) I tried to test my code with every scenario that came into my mind. So I hope it works. 😃 |
Is anything still missing here? |
@andryyy Anything new in terms of merging this? |
I wonder what happens with all the Software when they load the same certificate twice. |
I've already checked the services implementation and documentation here. Since it's documented OpenSSL functionality that loading the same certificate twice actually does nothing and postfix/dovecot/nginx don't care about the certificate handling/parsing itself, it should (and does!) work flawlessly in my opinion. :-) |
What's the exact state with this PR, @OpenLarry? Now as #2509 was merged in the past, I'd guess that most of the code is outdated and not compatible anymore. Any input from @mhofer117 for this? |
I had this included in #2509 initially because I thought ECDSA would be merged first. Then removed it so #2509 could be merged. However my changes are still ready here: OpenLarry#1 Personally I have no need for ECDSA certs so i'm not maintaining it, but that PR should solve almost all conflicts |
I've already merged the mentioned PR by mhofer117 locally and it seems to work. But I wasn't able to test everything yet. I will try to do that in the next two days and update this PR afterwards. :-) |
Sorry for the late reply, had a lot of stuff to do during the last days... I've merged the PR by @mhofer117 containing the ECDSA adjustments for the SNI part and it looks good to me. But I haven't tested the SNI part yet, because I have no need for that. Maybe someone else wants to try that out and verify that everything works properly? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
Just saw your rebase on master, possible to change the base branch to staging and rerebase? :p |
Sure! I will do that in the coming days and also clean up this branch. :-) |
Using ECDSA with last acme.sh deploy hook. Really need that to be merged. Any news ? |
@christianbur I had a previous version of the deploy script that was working well. Edit: I have mailcow up-to-date and don't want to play with symlinks in docker |
2634fdf
to
48a48bb
Compare
I've squashed all messy commits together and rebased it on the current staging branch. Seems to work (and is already working for me for years). |
Yes, keep in mind there are like 47838374 different setups and thinks will get dirty. We will need to be prepared. Thank you, Aaron! :) |
What's the status on that PR ? |
@SecT0uch If you want to store ECDSA certificates in the (RSA) cert files (cert.pem, key.pem), this would have been possible simply with symlinks. With your change in acme.sh, you destroyed my plugin and also my mail setup, because DANE/TLSA was broken. @SecT0uch -> Please undo the change as soon as possible. Create symlink in directory ./mailcow-dockerized/data/assets/ssl
|
Because you are including custom changes in a public repository that breaks a default mailcow installation. You broke my installation in the first place with your changes on the acme plugin. If you want to keep using the custom changes you made on mailcow, you should fork the acme plugin and make your changes on your side. |
48a48bb
to
7ad7461
Compare
7ad7461
to
b73b353
Compare
b73b353
to
71718f3
Compare
Hello everyone, as i have taken the position to maintain the repository and i'm not 100% sure what your PR does i would kindly ask you to describe what the benefits of ECDSA are and if it will break existing installations. I've saw, that you've changed also the dovecot.conf for alt_certs. How does dovecot/postfix behave if these certs are not generated? |
This is a squashed commit of the following: commit db8051bc234c5fa67aa87a7a94f9e89eaf0e7dac Merge: 2634fdf 0402068 Author: Aaron Larisch <[email protected]> Date: Tue May 24 20:44:38 2022 +0200 Merge branch 'master' into add-ecdsa-support commit 2634fdf Merge: 0962b90 116c791 Author: Aaron Larisch <[email protected]> Date: Wed Nov 10 08:53:21 2021 +0100 Merge branch 'master' into add-ecdsa-support commit 0962b90 Merge: 6152271 d90d4f9 Author: Aaron Larisch <[email protected]> Date: Wed Jun 9 11:33:34 2021 +0200 Merge branch 'master' into add-ecdsa-support commit 6152271 Merge: 72261e6 6426476 Author: Aaron Larisch <[email protected]> Date: Fri Feb 26 18:20:30 2021 +0100 Merge branch 'master' into add-ecdsa-support commit 72261e6 Merge: 3a1cce2 0846013 Author: Aaron Larisch <[email protected]> Date: Wed Dec 16 21:33:55 2020 +0100 Merge branch 'master' into add-ecdsa-support commit 3a1cce2 Merge: 6a01796 c1034b8 Author: Aaron Larisch <[email protected]> Date: Tue Sep 15 10:51:32 2020 +0200 Merge branch 'master' into add-ecdsa-support commit 6a01796 Merge: 812adb0 9685b4b Author: Aaron Larisch <[email protected]> Date: Tue Jul 21 14:07:56 2020 +0200 Merge branch 'master' into add-ecdsa-support commit 812adb0 Author: Aaron Larisch <[email protected]> Date: Sun Jul 5 00:12:21 2020 +0200 Fix TLSA records for ECDSA and RSA certs in DNS diagnostics Disables TLS 1.3 for the test connection to limit to RSA or ECDSA ciphers. commit 83c9769 Merge: 6fb29ab becc505 Author: Aaron Larisch <[email protected]> Date: Sat Jul 4 23:03:45 2020 +0200 Merge branch 'master' into add-ecdsa-support commit 6fb29ab Merge: 3131e17 b933a30 Author: Aaron Larisch <[email protected]> Date: Thu May 21 11:34:30 2020 +0200 Merge branch 'master' into add-ecdsa-support commit 3131e17 Merge: 1929216 7fa10cc Author: Aaron Larisch <[email protected]> Date: Thu Apr 16 18:20:39 2020 +0200 Merge branch 'master' into add-ecdsa-support commit 1929216 Merge: a0edf84 a9947e9 Author: Aaron Larisch <[email protected]> Date: Sat Mar 21 08:38:07 2020 +0100 Merge branch 'master' into add-ecdsa-support commit a0edf84 Merge: 6152b42 b5c844d Author: Aaron Larisch <[email protected]> Date: Thu Feb 13 13:52:09 2020 +0100 Merge branch 'master' into add-ecdsa-support commit 6152b42 Merge: 85b791b e6bb306 Author: Aaron Larisch <[email protected]> Date: Wed Jan 15 10:14:18 2020 +0100 Merge branch 'master' into add-ecdsa-support commit 85b791b Merge: c233993 ff74b8a Author: Aaron Larisch <[email protected]> Date: Tue Dec 17 15:21:10 2019 +0100 Merge branch 'master' into add-ecdsa-support commit c233993 Merge: eee0238 4e8b2bf Author: Aaron Larisch <[email protected]> Date: Sat Dec 7 17:17:05 2019 +0100 Merge branch 'master' into add-ecdsa-support commit eee0238 Merge: 9e1ff33 1d1a9a2 Author: Aaron Larisch <[email protected]> Date: Fri Nov 8 12:53:51 2019 +0100 Merge branch 'master' into add-ecdsa-support commit 9e1ff33 Merge: ab16425 ea4da60 Author: Aaron Larisch <[email protected]> Date: Fri Nov 1 16:06:41 2019 +0100 Merge branch 'master' into add-ecdsa-support commit ab16425 Merge: c049926 573e62f Author: Aaron Larisch <[email protected]> Date: Thu Oct 31 13:57:01 2019 +0100 Merge branch 'master' into add-ecdsa-support commit c049926 Merge: 6a6d6c4 c431615 Author: Aaron Larisch <[email protected]> Date: Thu Oct 31 13:55:28 2019 +0100 Merge pull request #1 from mhofer117/tls-sni-ecdsa Change line endings in functions.inc.php back to CRLF commit c431615 Author: Marcel Hofer <[email protected]> Date: Sun Oct 20 19:02:17 2019 +0200 remove empty docker-entrypoint.sh commit efd6cd1 Merge: a2a0821 6a6d6c4 Author: Marcel Hofer <[email protected]> Date: Sun Oct 20 19:00:07 2019 +0200 Merge remote-tracking branch 'OpenLarry/add-ecdsa-support' into tls-sni-ecdsa # Conflicts: # data/Dockerfiles/acme/docker-entrypoint.sh # data/conf/dovecot/dovecot.conf # data/conf/nginx/site.conf # data/conf/postfix/main.cf # data/web/inc/ajax/dns_diagnostics.php # data/web/inc/functions.inc.php # docker-compose.yml # generate_config.sh # update.sh commit a2a0821 Merge: 4a62809 05e7c95 Author: Marcel Hofer <[email protected]> Date: Sun Oct 20 18:50:16 2019 +0200 Merge branch 'tls-sni' into tls-sni-ecdsa commit 4a62809 Author: Marcel Hofer <[email protected]> Date: Sat Oct 19 13:04:02 2019 +0200 [SSL] add optional ecdsa certs in addition to rsa certs commit 6a6d6c4 Merge: 351abd2 9f66b83 Author: Aaron Larisch <[email protected]> Date: Tue Oct 1 11:01:28 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 351abd2 Merge: eddb269 0485379 Author: Aaron Larisch <[email protected]> Date: Mon Sep 9 17:40:47 2019 +0200 Merge branch 'master' into add-ecdsa-support commit eddb269 Merge: 9d13ead 6e82a35 Author: Aaron Larisch <[email protected]> Date: Thu Aug 29 11:36:03 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 9d13ead Merge: 478c4d1 f21cf13 Author: Aaron Larisch <[email protected]> Date: Thu Aug 8 13:22:58 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 478c4d1 Merge: 46dbf3b 7665cc2 Author: Aaron Larisch <[email protected]> Date: Thu Jun 27 14:49:09 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 46dbf3b Merge: 680a272 69fb7f7 Author: Aaron Larisch <[email protected]> Date: Fri May 31 12:33:32 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 680a272 Merge: f69559f b20ff13 Author: Aaron Larisch <[email protected]> Date: Tue May 7 12:29:34 2019 +0200 Merge branch 'master' into add-ecdsa-support commit f69559f Merge: 3e8a958 cd88165 Author: Aaron Larisch <[email protected]> Date: Mon Apr 15 12:55:41 2019 +0200 Merge branch 'master' into add-ecdsa-support commit 3e8a958 Merge: 956a487 4aae727 Author: Aaron <[email protected]> Date: Mon Mar 18 16:52:37 2019 +0100 Merge branch 'master' into add-ecdsa-support commit 956a487 Author: Aaron Larisch <[email protected]> Date: Sun Mar 17 12:34:56 2019 +0100 Set SKIP_ECDSA_CERT to y by default commit 7103fe7 Author: Aaron Larisch <[email protected]> Date: Sun Mar 17 11:05:05 2019 +0100 Add SKIP_ECDSA_CERT config parameter commit 91fca4f Author: Aaron Larisch <[email protected]> Date: Sat Mar 16 18:48:28 2019 +0100 Show TLSA records for ECDSA certificates in DNS diagnostics commit cc521b0 Author: Aaron Larisch <[email protected]> Date: Sat Mar 16 13:04:03 2019 +0100 Add ECDSA support Co-authored-by: Marcel Hofer <[email protected]>
71718f3
to
bd6196a
Compare
I added the ECDSA certificate support like we have discussed in #2426 .
I tried to modify the bash script as less as possible to reduce the time for code review/testing and I tried to use the same coding style like before. However, I decided to move some code into separate functions to avoid code duplication.
A few notes:
I've tested migration (using custom and Letsencrypt certificates) and fresh installations. I've checked all services using testssl.sh and it reports two certificates or one certificate depending on whether an ECDSA certificate exists or not. Looks good to me, so I'm looking forward to feedback! :-)
Of course I can add a few lines to the documentation as well.
Closes #2426