-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
EC CAs being signed with RSA #196
Comments
Can you try with the latest v3.0.5 code? I think this may have been fixed in commits made yesterday. Also, please note that v3.0.5 is not production ready.
I’ll fix GitHub so it defaults to v3.0.4.
Eric
… On Feb 27, 2018, at 04:51:17, eccgecko ***@***.***> wrote:
I've been having an issue with EasyRSA 3.0.5 that is causing an interoperability issue when using mbedTLS.
When creating a new CA using EC, the CA is being signed with RSA 2048, not ecdsa.
I have three CAs, one created using 3.0.0, one using 3.0.3, and one using 3.0.5.
On the first 2, the CAs reports
Signature Algorithm: ecdsa-with-SHA256 Public Key Algorithm: id-ecPublicKey
However, with the CA created using 3.0.5, it instead reports
Signature Algorithm: sha256WithRSAEncryption Public Key Algorithm: rsaEncryption
I am using the same settings in the vars file regarding EC
`# Choose a size in bits for your keypairs. The recommended value is 2048. Using
2048-bit keys is considered more than sufficient for many years into the
future. Larger keysizes will slow down TLS negotiation and make key/DH param
generation take much longer. Values up to 4096 should be accepted by most
software. Only used when the crypto alg is rsa (see below.)
#set_var EASYRSA_KEY_SIZE 2048
The default crypto mode is rsa; ec can enable elliptic curve support.
Note that not all software supports ECC, so use care when enabling it.
Choices for crypto alg are: (each in lower-case)
* rsa
* ec
set_var EASYRSA_ALGO ec
Define the named curve, used in ec mode only:
set_var EASYRSA_CURVE secp384r1`
Is there a reason this is the case on 3.0.5? It is causing an issue when using OpenVPN built using mbedTLS (I am also reporting a bug to mbedTLS because OpenVPN using OpenSSL can connect using the same CA cert/key pairs just fine)
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub <#196>, or mute the thread <https://github.com/notifications/unsubscribe-auth/ABt4P1ujYF58iAHPrL_NnHPBBJ1AfaERks5tY94lgaJpZM4SUueb>.
|
Yeah I didn't realise until I was told today that I wasn't using the release branch, so that was my bad. I have created a new CA with the latest 3.0.5 code and it certainly seems to be an improvement. The signature algorithm for the CA is now using ecdsa, so that's good. However, it seems that on 3.0.4 it uses ecdsa-with-SHA256, whereas on 3.0.5 it uses ecdsa-with-SHA1. Not that SHA1 is inherently unsafe, but it does seem like it is a regression, and it is probably safer for the default to be SHA256 where possible. When I get some time tomorrow I will create a new openvpn server using the new 3.0.5 CA and client/key pairs and will report on whether mbedTLS can connect with the ecdsa signed CA. |
I've just tried this on 9bd3241 (HEAD on v3.0.5 branch at the time of this writing) and could not reproduce this. The
After that I executed the following commands:
As you can see, the signature algorithm is |
Ok, so I performed exactly the same actions as you, and on the same commit. For some reason, on MacOS Sierra 10.12.6, the problem persists, and the latest 3.0.5 commit is signing the CA using However, on Linux Ubuntu 17.10, the output is the same as yours, and it signs using What's interesting is that on MacOS 10.12.6, EasyRSA 3.0.4 signs EC CAs with |
What is the difference in versions of OpenSSL?
…---
Eric F Crist
On 2018-03-05 11:43, eccgecko wrote:
Ok, so I performed exactly the same actions as you, and on the same
commit.
For some reason, on MacOS Sierra 10.12.6, the problem persists, and
the latest 3.0.5 commit is signing the CA using ecsda-with-SHA1
However, on Linux Ubuntu 17.10, the output is the same as yours, and
it signs using ecdsa-with-SHA256
What's interesting is that on MacOS 10.12.6, EasyRSA 3.0.4 signs EC
CAs with ecdsa-with-SHA256
--
You are receiving this because you commented.
Reply to this email directly, view it on GitHub [1], or mute the
thread [2].
*
Links:
------
[1]
#196 (comment)
[2]
https://github.com/notifications/unsubscribe-auth/ABt4P6QMsmPqsdjpqQD_JMx77xRXxCImks5tbXlHgaJpZM4SUueb
|
Ah, that's it. I am sorry - I completely forgot that I edited the openssl directory on the 3.0.4 vars to use an openssl binary contained in the latest version of a Homebrew installed LibreSSL package. My mistake. I see that adding that directory to the 3.0.5 vars fixes the SHA1 issue. I believe that if you run EasyRSA on MacOS without having a newer OpenSSL version installed via brew, and the openssl directory linked in the vars file, then this problem will continue, as Apple have deprecated OpenSSL in favour of their own managed crypto libraries, so the version of OpenSSL installed in /usr/bin/openssl is quite old (0.9.8zh). |
The lastest version of MacOS uses LibreSSL, which is problematic due to some restrictions on environment variables. |
This issue should be resolved release v3.0.5, with added support for LibreSSL. |
I've been having an issue with EasyRSA 3.0.5 that is causing an interoperability issue when using mbedTLS.
When creating a new CA using EC, the CA is being signed with RSA 2048, not ecdsa.
I have three CAs, one created using 3.0.0, one using 3.0.3, and one using 3.0.5.
On the first 2, the CAs report
Signature Algorithm: ecdsa-with-SHA256 Public Key Algorithm: id-ecPublicKey
However, with the CA created using 3.0.5, it instead reports
Signature Algorithm: sha256WithRSAEncryption Public Key Algorithm: rsaEncryption
I am using the same settings in the vars file regarding EC
`#set_var EASYRSA_KEY_SIZE 2048
set_var EASYRSA_ALGO ec
set_var EASYRSA_CURVE secp384r1`
Is there a reason this is the case on 3.0.5? It is causing an issue when using OpenVPN built using mbedTLS (I am also reporting a bug to mbedTLS because OpenVPN using OpenSSL can connect using the same CA cert/key pairs just fine)
The text was updated successfully, but these errors were encountered: