My scrapbook about almost anything I stumble upon in my tech world. If you find anything useful don't forget to give thumbs-up :)

Breaking

Wednesday, August 30, 2023

Base64 Encoding & Decoding in GoLang


Encoding and decoding refer to the process of putting a sequence of characters into a specialized format for efficient transmission or storage. In computers, encoding is the process of putting a sequence of characters into a specialized format for efficient transmission or storage [google].  Keep in mind that Encoding/Decoding is not encryption/decryption.

All Linux/Mac operating system comes with binary "base64" by default where MS-Windows does not provide the functionality by default in "Command Prompt" but in "Powershell".  For using "base64" command in Command prompt, you have to install either this utility or "openssl". 

Golang also provides encoding/base64 package to achieve the same. It implements base64 encoding as specified by RFC 4648


Output:



Like the below page to get the update  
Facebook Page      Facebook Group      Twitter Feed      Telegram Group

No comments:

Post a Comment

Disclaimer

The postings on this site are my own and don't necessarily represent IBM's or other companies positions, strategies or opinions. All content provided on this blog is for informational purposes and knowledge sharing only.
The owner of this blog makes no representations as to the accuracy or completeness of any information on this site or found by following any link on this site. The owner will not be liable for any errors or omissions in this information nor for the availability of this information. The owner will not be liable for any losses, injuries, or damages from the display or use of his information.