From d6f35b90d914f3e18a1367048206dc7717c3a80d Mon Sep 17 00:00:00 2001 From: Petr Menšík Date: Mar 01 2018 16:45:16 +0000 Subject: Custom hmacsha.h header is no longer required. The same with custom include paths. --- diff --git a/bind9-hmacsha.h b/bind9-hmacsha.h deleted file mode 100644 index 286cafc..0000000 --- a/bind9-hmacsha.h +++ /dev/null @@ -1,169 +0,0 @@ -/* - * Copyright (C) 2005-2007, 2009 Internet Systems Consortium, Inc. ("ISC") - * - * Permission to use, copy, modify, and/or distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: hmacsha.h,v 1.9 2009-02-06 23:47:42 tbox Exp $ */ - -/*! \file isc/hmacsha.h - * This is the header file for the HMAC-SHA1, HMAC-SHA224, HMAC-SHA256, - * HMAC-SHA334 and HMAC-SHA512 hash algorithm described in RFC 2104. - */ - -#ifndef ISC_HMACSHA_H -#define ISC_HMACSHA_H 1 - -#include -#include -#include -#include -#include - -#define ISC_HMACSHA1_KEYLENGTH ISC_SHA1_BLOCK_LENGTH -#define ISC_HMACSHA224_KEYLENGTH ISC_SHA224_BLOCK_LENGTH -#define ISC_HMACSHA256_KEYLENGTH ISC_SHA256_BLOCK_LENGTH -#define ISC_HMACSHA384_KEYLENGTH ISC_SHA384_BLOCK_LENGTH -#define ISC_HMACSHA512_KEYLENGTH ISC_SHA512_BLOCK_LENGTH - -#ifdef ISC_PLATFORM_OPENSSLHASH -#include - -typedef HMAC_CTX isc_hmacsha1_t; -typedef HMAC_CTX isc_hmacsha224_t; -typedef HMAC_CTX isc_hmacsha256_t; -typedef HMAC_CTX isc_hmacsha384_t; -typedef HMAC_CTX isc_hmacsha512_t; - -#else - -typedef struct { - isc_sha1_t sha1ctx; - unsigned char key[ISC_HMACSHA1_KEYLENGTH]; -} isc_hmacsha1_t; - -typedef struct { - isc_sha224_t sha224ctx; - unsigned char key[ISC_HMACSHA224_KEYLENGTH]; -} isc_hmacsha224_t; - -typedef struct { - isc_sha256_t sha256ctx; - unsigned char key[ISC_HMACSHA256_KEYLENGTH]; -} isc_hmacsha256_t; - -typedef struct { - isc_sha384_t sha384ctx; - unsigned char key[ISC_HMACSHA384_KEYLENGTH]; -} isc_hmacsha384_t; - -typedef struct { - isc_sha512_t sha512ctx; - unsigned char key[ISC_HMACSHA512_KEYLENGTH]; -} isc_hmacsha512_t; -#endif - -ISC_LANG_BEGINDECLS - -void -isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, - unsigned int len); - -void -isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx); - -void -isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, - unsigned int len); - -void -isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); - -isc_boolean_t -isc_hmacsha1_verify(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); - - -void -isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, - unsigned int len); - -void -isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx); - -void -isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, - unsigned int len); - -void -isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); - -isc_boolean_t -isc_hmacsha224_verify(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); - - -void -isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, - unsigned int len); - -void -isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx); - -void -isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, - unsigned int len); - -void -isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); - -isc_boolean_t -isc_hmacsha256_verify(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); - - -void -isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, - unsigned int len); - -void -isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx); - -void -isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, - unsigned int len); - -void -isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); - -isc_boolean_t -isc_hmacsha384_verify(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); - - -void -isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, - unsigned int len); - -void -isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx); - -void -isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, - unsigned int len); - -void -isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); - -isc_boolean_t -isc_hmacsha512_verify(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); - -ISC_LANG_ENDDECLS - -#endif /* ISC_HMACSHA_H */ diff --git a/dnsperf.spec b/dnsperf.spec index 86e40f0..1665669 100644 --- a/dnsperf.spec +++ b/dnsperf.spec @@ -5,7 +5,6 @@ Release: 14%{?dist} License: MIT Url: http://www.nominum.com/support/measurement-tools/ Source: ftp://ftp.nominum.com/pub/nominum/dnsperf/%{version}/dnsperf-src-%{version}-1.tar.gz -Source2: bind9-hmacsha.h Source3: queryfile-example-current.gz Patch1: dnsperf-buffer-inline.patch BuildRequires: bind-devel >= 9.3.0, libcap-devel, gzip, openssl-devel @@ -18,14 +17,11 @@ For more information, see the dnsperf(1) and resperf(1) man pages. %prep %setup -q -n dnsperf-src-%{version}-1 -cp %{SOURCE2} hmacsha.h %patch1 -p1 -b .buffer -sed -i "s//\"hmacsha.h\"/" dns.c - %build -%configure -%make_build CFLAGS="$RPM_OPT_FLAGS -I/usr/include/bind9 -I." +%configure +%make_build %install %make_install