![]() The term Base64 is taken from the Multipurpose Internet Mail Extensions (MIME) standard, which is widely used for HTTP and XML, and was originally developed for encoding email attachments for transmission. For instance, using this encoding, three 8-bit bytes are converted into four 6-bit groups. ![]() This is done using only the characters A-Z, a-z, 0-9, +, and / in order to represent data, with = used to pad data. What Is Base64?īefore moving more deeper in the article, let's define what we mean by Base64.īase64 is a way in which 8-bit binary data is encoded into a format that can be represented in 6 bits. The program is illustrated as a standalone local program, but you can apply the concept to different applications like sending your encoded image from your mobile device to a server, and many other applications. In this article, I will show you how we can use Python to encode and decode a binary image. What would be the workaround to avoid such an issue? The answer is Base64 encoding. Well, it seems that you attempted to send your file in its raw bits and bytes format, while the media used was designed for streaming text. You're amazed that the file wasn't received properly on the other side-the file just contained strange characters! ![]() Say you have a binary image file you wanted to transfer across a network.
0 Comments
Leave a Reply. |