Introduction to Library Functions puid_b64(3) NAME puid_b64tostr(), puid_strtob64r() - base-64 conversion func- tions SYNOPSIS #include "puid_b64.h" char *puid_b64tostr(char *s); char *puid_strtob64(char *s); DESCRIPTION These functions convert strings to and from a slightly modi- fied version of the base-64 encoding specified in RFC 1421 (see WARNING below). The puid_strtob64() function converts an unencoded string to base-64, and puid_b64tostr() decodes strings encoded by puid_strtob64(). Certain data sent to puid_authcdbm(8) must be passed as base-64 encoded strings. In particular, the password hash and certificates must be sent and stored in this format. RETURN VALUES When they succeed, both functions return a pointer to a newly allocated string, which the caller may later free(3). When they fail they return a null string, with errno set to 0, meaning bad input. WARNING Contrary to RFC 1421, puid_strtob64() does not insert a CR/LF pair into the output when encoding long lines. Nor can puid_b64tostr() convert base-64 input that includes embedded newlines. These functions should not be used to prepare RFC 1421 compliant input or to decode RFC 1421 com- pliant encodings! SEE ALSO puid_authcdbm(8) AUTHOR These functions are front-ends to slightly modified versions of the IMAP version 4.7 functions rfc822_base64() and rfc822_binary(). Local modifications by Jeff Smith (jsmith@purdue.edu). SunOS 5.8 Last change: 1