* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
* See the COPYRIGHT file distributed with this work for additional
* information regarding copyright ownership.
* \brief This is the header file for the HMAC-MD5 keyed hash algorithm
#include <isc/platform.h>
#define ISC_HMACMD5_KEYLENGTH 64
#ifdef ISC_PLATFORM_OPENSSLHASH
#include <openssl/opensslv.h>
#include <openssl/hmac.h>
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
typedef pk11_context_t isc_hmacmd5_t;
unsigned char key[ISC_HMACMD5_KEYLENGTH];
isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key,
isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx);
isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf,
isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest);
isc_hmacmd5_verify(isc_hmacmd5_t *ctx, unsigned char *digest);
isc_hmacmd5_verify2(isc_hmacmd5_t *ctx, unsigned char *digest, size_t len);
isc_hmacmd5_check(int testing);
#endif /* !PK11_MD5_DISABLE */
#endif /* ISC_HMACMD5_H */