#include <openssl/evp.h>
#include <openssl/aes.h>
#include <openssl/rand.h>
#include <openssl/hmac.h>
#include <openssl/err.h>
#include <openssl/crypto.h>
#include <openssl/bio.h>
#include <openssl/buffer.h>
#include <openssl/pem.h>
#include <openssl/x509.h>
#include <cstring>
#include <iostream>

const EVP_CIPHER* get_aes_cipher(size_t key_len);

void encrypt_aeshmack(const uint8_t *in, const size_t inlen, 
                     uint8_t *&out, size_t &outlen, uint8_t *ckey);

int decrypt_aeshmack(const uint8_t *in, const size_t inlen,
                    uint8_t *&out, size_t &outlen, uint8_t *ckey);

