Logo Search packages:      
Sourcecode: nbsmtp version File versions  Download package

base64.c File Reference

Detailed Description

base-64 conversion routines.

Eric S. Raymond <esr@snark.thyrsus.com>.
For license terms, see the file COPYING in this directory.

This base 64 encoding is defined in RFC2045 section 6.8, "Base64 Content-Transfer-Encoding", but lines must not be broken in the scheme used here.

Definition in file base64.c.

#include <ctype.h>

Go to the source code of this file.


#define BAD   -1
#define DECODE64(c)   (isascii(c) ? base64val[c] : BAD)


int from64tobits (char *out, const char *in)
 base 64 to raw bytes in quasi-big-endian order, returning count of bytes
void to64frombits (unsigned char *out, const unsigned char *in, int inlen)
 Raw bytes in quasi-big-endian order to base 64 string (NUL-terminated).


static const char base64digits []
static const char base64val []

Generated by  Doxygen 1.6.0   Back to index