Skip to content

Instantly share code, notes, and snippets.

@jdye64
Created September 10, 2015 20:30
Show Gist options
  • Save jdye64/28c626b3586f2fa80629 to your computer and use it in GitHub Desktop.
Save jdye64/28c626b3586f2fa80629 to your computer and use it in GitHub Desktop.
Extract OpenSSH Public key from Google Cloud p12 file
cat filename.p12 | openssl pkcs12 -nodes -nocerts -passin pass:notasecret | openssl rsa > secret.pem
chmod 600 secret.pem
ssh-keygen -y -f secret.pem > OpenSSHPublicKey.pub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment