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

How to generate .key and .crt from .p12 file #1743

Closed
JACKHAHA363 opened this issue Mar 2, 2020 · 1 comment
Closed

How to generate .key and .crt from .p12 file #1743

JACKHAHA363 opened this issue Mar 2, 2020 · 1 comment

Comments

@JACKHAHA363
Copy link

In the ipsec/manual, I can find one user.p12 file but I don't see user.key or user.crt. I realize that the latter two files are generated by user.p12 so I tried

openssl pkcs12 -in <user>.p12 -out <user>.key

But it asks for Enter Import Password and Enter PEM pass phrase. I am not sure what these two passwords are.

@JACKHAHA363
Copy link
Author

after installation you can see

  "    \"#        The p12 and SSH keys password for new users is XXXXXX       #\"\n",

Then you do

openssl pkcs12 -in path.p12 -out newfile.crt.pem -clcerts -nokeys -passin 'pass:XXXXXX'
openssl pkcs12 -in path.p12 -out newfile.key.pem -nocerts -nodes -passin 'pass:XXXXXX'

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