gsasl
2.2.1
|
Go to the source code of this file.
Functions | |
int | gsasl_base64_to (const char *in, size_t inlen, char **out, size_t *outlen) |
int | gsasl_base64_from (const char *in, size_t inlen, char **out, size_t *outlen) |
int | gsasl_hex_to (const char *in, size_t inlen, char **out, size_t *outlen) |
int | gsasl_hex_from (const char *in, char **out, size_t *outlen) |
int gsasl_base64_from | ( | const char * | in, |
size_t | inlen, | ||
char ** | out, | ||
size_t * | outlen | ||
) |
gsasl_base64_from:
in | input byte array |
inlen | size of input byte array |
out | pointer to newly allocated output byte array |
outlen | pointer to size of newly allocated output byte array |
Decode Base64 data. The @out buffer must be deallocated by the caller.
Return value: Returns GSASL_OK on success, GSASL_BASE64_ERROR if input was invalid, and GSASL_MALLOC_ERROR on memory allocation errors.
Since: 0.2.2
int gsasl_base64_to | ( | const char * | in, |
size_t | inlen, | ||
char ** | out, | ||
size_t * | outlen | ||
) |
gsasl_base64_to:
in | input byte array. |
inlen | size of input byte array. |
out | pointer to newly allocated base64-encoded string. |
outlen | pointer to size of newly allocated base64-encoded string. |
Encode data as base64. The @out string is zero terminated, and @outlen holds the length excluding the terminating zero. The @out buffer must be deallocated by the caller.
Return value: Returns GSASL_OK on success, or GSASL_MALLOC_ERROR if input was too large or memory allocation fail.
Since: 0.2.2
int gsasl_hex_from | ( | const char * | in, |
char ** | out, | ||
size_t * | outlen | ||
) |
gsasl_hex_from:
in | input byte array |
out | pointer to newly allocated output byte array |
outlen | pointer to size of newly allocated output byte array |
Decode hex data. The @out buffer must be deallocated by the caller.
Return value: Returns GSASL_OK on success, GSASL_BASE64_ERROR if input was invalid, and GSASL_MALLOC_ERROR on memory allocation errors.
Since: 1.10
int gsasl_hex_to | ( | const char * | in, |
size_t | inlen, | ||
char ** | out, | ||
size_t * | outlen | ||
) |
gsasl_hex_to:
in | input byte array. |
inlen | size of input byte array. |
out | pointer to newly allocated hex-encoded string. |
outlen | pointer to size of newly allocated hex-encoded string. |
Hex encode data. The @out string is zero terminated, and @outlen holds the length excluding the terminating zero. The @out buffer must be deallocated by the caller.
Return value: Returns GSASL_OK on success, or GSASL_MALLOC_ERROR if input was too large or memory allocation fail.
Since: 1.10