JoshKaufman / ursa

URSA - RSA public/private key OpenSSL bindings for Node.js
Other
619 stars 135 forks source link

[SOLVED] Native RSA in node v10.12+ #178

Open coolaj86 opened 5 years ago

coolaj86 commented 5 years ago

Node v10+ has Native RSA Support now

As of node v10.12, we now have native RSA key generation:

PEM <-> JWK

R.I.P. uRSA

We'll still have to use jwk-to-pem, and rsa-pem-to-jwk for conversion, but I think it's safe to let uRSA R.I.P. is it not?

~It looks like the one thing that it does that still can't be done in node (aside from splitting the key into components, which can be done with reasonable memory and cpu efficiently using asn1.js) is converting ssh public keys to standard pems.~

Edit: It turns out that PEM-to-SSH and SSH-to-PEM are trivial to do, so I've added that functionality to Rasha.js. The format for SSH keys is just [32-bit length]["ssh-rsa"] [32-bit length][rsa n] [32-bit length][rsa e]

Is there anything else that's still missing from node?

rzr commented 5 years ago

Try: https://github.com/JoshKaufman/ursa/pull/180 Review welcome too

Maintainer feedback welcome, is project orphaned ?