| 184 | } |
| 185 | |
| 186 | static const char * |
| 187 | remove_base64_padding(string& str) |
| 188 | { |
| 189 | |
| 190 | while (str.length() > 0 && str[str.length() - 1] == '=') |
| 191 | str.pop_back(); |
| 192 | |
| 193 | return str.c_str(); |
| 194 | } |
| 195 | |
| 196 | bool |
| 197 | base64_decode(const char *str, vector<unsigned char>& storage, bool urlTransform, bool padding) |