Base64 encode data

You may encode binary data using alphanumeric code table by (amongst others) the base64 utility.

Encode binary file:

base64 mypic.jpg > mypic.txt

As result the binary image file gets encoded as an alphanumeric text file suitable for enclosing into text messages.

Decode the alphanumeric file back to the binary original (under a different name):

base64 -d mypic.txt > mypic2.jpg

This method can find many practical uses, for example, including an image file into text notes created by a simplistic software incapable of embedding graphics, or storing at your bookshelf a multimedia file (image or sound) as a printed hardcopy of a base64 encoded file.

Advertisements


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s