teleport-a-binary-file-with-base64

12y, 99d ago [edited]

teleport a binary file between ssh terminals with base64

create a base64 representation of the binary file:

openssl enc -e -base64 -in /path/to/binary.pfx

create a binary file from its base64 representation:

cat | openssl enc -d -base64 -out /path/to/binary.pfx

The first command will put the ASCII representation of the file to stdout. The second command will accept the ASCII representation of the binary file and write it to the -out path. Once you paste in the ASCII to the second command, press ctrl-d once or twice to write the binary data out.

You might want to verify some hashes of the file on both sides:

md5sum /path/to/binary.pfx

Comments

We'll email a 6-digit code to verify your comment and notify you of replies.

hide preview ▲show preview ▼
Leave first comment to start a conversation!