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

Convert PEM to CryptoKey #394

Open
gabrypulzio opened this issue Feb 1, 2024 · 0 comments
Open

Convert PEM to CryptoKey #394

gabrypulzio opened this issue Feb 1, 2024 · 0 comments

Comments

@gabrypulzio
Copy link

Hi,
I followed the example at

async function createOpenSSLPrivateKey() {
to create an encrypted private key in PEM format.

Now I would like to import the PEM data back to a CrytpoKey. Always in the same example file there's a method: pkijs.RSAPrivateKey.fromBER(decryptedKey) to create a RSAPrivateKey from the decrypted private key but I can't find a way to create a CrytpoKey instead or to import the RSAPrivateKey into a CrytpoKey.

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

1 participant