bglibs: base64.h Source File

bglibs

base64.h
1 #ifndef BASE64__H__
2 #define BASE64__H__
3
4 #include "str.h"
5
6 #define BASE64_PAD '='
7
8 extern const char base64_bin2asc[64];
9 extern void base64_encode_whole(const unsigned char bin[3], char encoded[4]);
10 extern void base64_encode_part(const unsigned char bin[3], unsigned len,
11 char encoded[4]);
12 extern int base64_encode_line(const unsigned char* bin, unsigned long len,
13 str* encoded);
14
15 extern const signed char base64_asc2bin[256];
16 extern int base64_decode_part(const char encoded[4],
17 unsigned char bin[3]);
18 extern int base64_decode_line(const char* encoded, str* bin);
19
20 #endif
str
Definition: str.h:30