I recently received a PPK file to connect to a company server, as an Ubuntu user I needed to convert to the PEM format which is supported by OpenSSH.

Glossary:
PPK (PuTTY Private Key): File generated by the program PuttyGEN
PEM (Privacy Enhanced Mail): Base64 encoded certificate file


1. install the tool putty tools on your linux:

$ sudo apt-get install putty-tools


two. We convert the PPK file to PEM format:

$ puttygen henrique.fernandes.ppk -O private-openssh -o myserver.pem

-O : Type of file we want to generate
-o : Converted file name


3. For security when we connect using the OpenSSH it checks that the identity file permissions are not wide open. We then need to 'close' the permissions of the generated file:

$ chmod 400 myserver.pem

If you, like me, never remember what permission numbering means: chmodcommand


4. Now we test the connection with the generated file:

$ ssh -i myserver.pem [email protected]
0 0 votos
Nota do Artigo
Subscribe
Notify of
guest
0 Comentários
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x