use Data.ByteString.Base64 and Data.Text.Encoding

Simplify some of the parsing and avoid unnecessary Data.Text
pack/unpack steps by moving from Codec.Binary.Base64* to
Data.ByteString.Base64*.  Also do proper UTF-8 encoding/decoding
of ByteStrings via the Data.Text.Encoding module.