-
-
Notifications
You must be signed in to change notification settings - Fork 202
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
Apple M1: Identity::from_pkcs8 does not work with "PKCS_ECDSA_P256_SHA256" #225
Comments
What does the PEM for one of these keys look like? |
@sfackler Here's the
And here's the raw PEM cert:
|
That's the certificate rather than the private key. |
Also, which OS are you running this on? |
Here's the key:
And I am running on OS with M1 |
Hmm, works fine on linux machine...
|
That makes me think that macOS's Security.framework library may not support ECDSA keys then unfortunately. |
I looked at this a bit. I don't think the issue is complete lack of ECDSA key support. I think it is an issue with importing ECDSA keys from unencrypted PKCS8 format. Using the command line I was hoping it might be possible to import the unencrypted pkcs8 by explicitly specifying the format, but I was unsuccessful. The keychain importer seems to interpret "pkcs8" to mean only encrypted pkcs8. If I manually specify pkcs8 format, the import fails trying to parse |
Hi,
The following code does not work for no apparent reason, and any hint for using ECDSA keys would be greatly appreciated!
NOTE:
CertificateParams
will generate the ECDSA keys as follows, and it should be the correct pkcs8 encoding:Similar code works fine for RSA keys...
The text was updated successfully, but these errors were encountered: