Skip to content
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

Extracting RSA or ECDSA Public Key from card #13

Closed
thotheolh opened this issue Jul 8, 2017 · 1 comment
Closed

Extracting RSA or ECDSA Public Key from card #13

thotheolh opened this issue Jul 8, 2017 · 1 comment

Comments

@thotheolh
Copy link

I noticed that there is no APDU command specifically meant to extract a particular Public Key from the card except during private key generation procedure. One alternative would probably be to store the public key into the ISO filesystem after key generation but this would be a problem if between different programs, they need to use a shared private key. One use case is an email signing program would generate the keypair but this private key would also be used for secure remote login program. The lack of ability to read the public key with a dedicated APDU command would mean that programs would need to traverse the entire filesystem or need to know the format of the public key stored into the ISO filesystem to be able to use the key in the card.

I hope consideration into a dedicate GET_PUBLIC_KEY command can be created for this purpose to allow all programs relying on IsoApplet to access the public keys in a uniform manner.

@philipWendland
Copy link
Owner

Hi,
the public key is being written into the file system according to the PKCS#15 standard during/after the key generation by OpenSC. So there is no need to traverse the complete file system. See PKCS#15 and let me know if you have further questions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants