sasl_decode64 - Decode base64 string

Synopsis

#include <sasl/saslutil.h>

int sasl_decode64(const char * input,
                unsigned inputlen,
               const char ** output,
               unsigned outmax,
               unsigned * outputlen);

Description

int sasl_decode64(const char * input,
unsigned inputlen,
const char ** output,
unasigned outmax,
unsigned * outputlen);

sasl_decode64 decodes a base64 encoded buffer.

Parameters:
  • input – Input data.
  • inputlen – The length of the input data.
  • output – contains the decoded data. The value of output can be the same as in. However, there must be enough space.
  • outmax – The maximum size of the output buffer.
  • outputlen – length of output.

Return Value

SASL callback functions should return SASL return codes. See sasl.h for a complete list. SASL_OK indicates success.

Other return codes indicate errors and should be handled.

See Also

RFC 4422,:saslman:sasl(3), sasl_decode(3), sasl_errors(3)