added Base64 encoding support