This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Source: http://www.sysmic.org/dotclear/index.php?post/2010/03/24/Convert-keys-betweens-GnuPG%2C-OpenSsh-and-OpenSSL | |
# OpenSSH private keys are directly understable by OpenSSL. You can test for example: | |
openssl rsa -in ~/.ssh/id_rsa -text | |
openssl dsa -in ~/.ssh/id_dsa -text | |
# So, you can directly use it to create a certification request: | |
openssl req -new -key ~/.ssh/id_dsa -out myid.csr | |
# You can also use your ssh key to create a sef-signed certificate: |