from something that starts with
-----BEGIN OPENSSH PRIVATE KEY-----
to something that starts with
-----BEGIN RSA PRIVATE KEY-----
🎉
#!/usr/bin/env bash | |
set -e | |
set -x | |
original_key=$1 | |
puttygen_destinaton=${original_key}_puttygen | |
rsa_destinaton=${original_key}_rsa | |
# FROM OPENSSH to SSH2 ENCRYPTED | |
puttygen $original_key -O private-sshcom -o $puttygen_destinaton | |
# FROM SSH2 ENCRYPTED format to RSA | |
ssh-keygen -i -f $puttygen_destinaton > $rsa_destinaton |
It worked! Thanks!