01234567891011121314151617181920212223242526
|
// util/rc2.h, version 1.0.1
// RC2 header file from libutil
// Copyright (C) 2021, Jakob Wakeling
// MIT Licence
#ifndef UTIL_RC2_H_PMXL29JH
#define UTIL_RC2_H_PMXL29JH
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
#include <stdlib.h>
struct rc2 { union { uint16_t k[64]; uint8_t l[128]; }; };
extern void rc2expand(struct rc2 *ctx, const uint8_t *key, int len, int ekl);
extern void rc2encrypt(struct rc2 *ctx, uint8_t *in, uint8_t *out);
extern void rc2decrypt(struct rc2 *ctx, uint8_t *in, uint8_t *out);
#ifdef __cplusplus
} // extern "C"
#endif
#endif // UTIL_RC2_H_PMXL29JH
|