Base64 Encoding Tools (base64.cc)

Functions for encoding and ecoding strings in MIME Base64 notation.

base64_encode()

char *base64_encode(char *str)

Convert 'str' to base64 encoding, and return a dynamically-allocated char* string with the result.

You must 'delete' the returned string when you've finished with it.

base64_decode()

char *base64_decode(char *str)

Convert 'str' from base64 format into a normal string, and return a dynamically-allocated char* string with the result.

You must 'delete' the returned string when you've finished with it.