implement base64 decode function (untested)