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

RSA needs to distinguish between RSA keys with different OIDs and parameters #17

Open
tniessen opened this issue Aug 13, 2019 · 2 comments

Comments

@tniessen
Copy link
Member

commented Aug 13, 2019

WebCrypto requires implementations to be able to distinguish between the OIDs rsaEncryption, sha1WithRSAEncryption, sha256WithRSAEncryption, sha384WithRSAEncryption, sha512WithRSAEncryption, id-RSAES-OAEP and id-RSASSA-PSS, and for the last two, we even need access to the ASN.1 parameters.

This is currently not possible using the KeyObject API.

@panva

This comment has been minimized.

Copy link

commented Aug 13, 2019

Similar for EC and (in the future, not part of webcrypto yet) OKP keys, you'll need the curve name from the key too.

@tniessen

This comment has been minimized.

Copy link
Member Author

commented Aug 13, 2019

@panva The curve name would have been part of my original proposal in nodejs/node#26854, I guess we could use a similar pattern for the other OIDs / parameters.

Another problem is that WebCrypto requires the ability to export keys with a different OID than they were imported with, so we would need to implement some kind of conversion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.