01234567891011121314151617181920212223242526
|
// util/base32.h, version 1.0.4
// Base32 header file from libutil
// Copyright (C) 2021, Jakob Wakeling
// MIT Licence
#ifndef UTIL_BASE32_H_2PSMZTB0
#define UTIL_BASE32_H_2PSMZTB0
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
#include <stdlib.h>
#define B32ELEN(x) (((x + 4) / 5) * 8)
#define B32DLEN(x) (((x + 7) / 8) * 5)
extern size_t b32encode(uint8_t *dst, uint8_t *src, size_t len);
extern size_t b32decode(uint8_t *dst, uint8_t *src, size_t len);
#ifdef __cplusplus
} // extern "C"
#endif
#endif // UTIL_BASE32_H_2PSMZTB0
|