I am using the following code snippet to base64 encode and decode a string using Boost C++ library.
//Base64 Encode Implementation using Boost C++ library con
The padding characters '=' are part of the b64 encoded data and should not be removed before decoding. b64 is encoded in blocks of 4 character, I suspect that while decoding it reads a '\0' instead of an expected '=' at the end of the string.