Man page - oath_base32_encode(3)
Packages contains this manual
- oath_bin2hex(3)
- oath_base32_encode(3)
- oath_totp_validate_callback(3)
- oath_strerror_name(3)
- oath_hex2bin(3)
- oath_totp_validate3(3)
- oath_base32_decode(3)
- oath_totp_validate2_callback(3)
- oath_hotp_validate_callback(3)
- oath_totp_validate(3)
- oath_init(3)
- oath_hotp_generate(3)
- oath_authenticate_usersfile(3)
- oath_done(3)
- oath_strerror(3)
- oath_totp_generate2(3)
- oath_totp_validate2(3)
- oath_hotp_validate(3)
- oath_totp_validate4(3)
- oath_totp_generate(3)
- oath_totp_validate3_callback(3)
- oath_check_version(3)
- oath_totp_validate4_callback(3)
apt-get install liboath-dev
Manual
oath_base32_encode
NAMESYNOPSIS
ARGUMENTS
DESCRIPTION
RETURNS
SINCE
REPORTING BUGS
COPYRIGHT
NAME
oath_base32_encode - API function
SYNOPSIS
#include <oath.h>
int oath_base32_encode(const char * in , size_t inlen , char ** out , size_t * outlen );
ARGUMENTS
const char * in
input string with binary data of length inlen
size_t inlen
length of input data in
|
char ** out |
pointer to newly allocated output string of length outlen , or NULL |
size_t * outlen
pointer to output variable holding length of out , or NULL
DESCRIPTION
Encode binary data into a string with base32 data.
The in parameter should contain inlen bytes of data to encode. The function allocates a new string in * out to hold the encoded data, and sets * outlen to the length of the data. The output string * out is zero-terminated (ASCII NUL), but the NUL is not counted in * outlen .
If out is NULL, then * outlen will be set to what would have been the length of * out on successful encoding.
If the caller is not interested in knowing the length of the output data out , then outlen may be set to NULL.
It is permitted but useless to have both out and outlen NULL.
RETURNS
On success OATH_OK (zero) is returned, OATH_BASE32_OVERFLOW is returned if the output would be too large to store, and OATH_MALLOC_ERROR is returned on memory allocation errors.
SINCE
1.12.0
REPORTING BUGS
Report bugs to <oath-toolkit-help@nongnu.org>. liboath home page: https://www.nongnu.org/oath-toolkit/ General help using GNU software: http://www.gnu.org/gethelp/
COPYRIGHT
Copyright ©
2009-2020 Simon Josefsson.
Copying and distribution of this file, with or without
modification, are permitted in any medium without royalty
provided the copyright notice and this notice are
preserved.