diff options
author | Guy Harris <guy@alum.mit.edu> | 2014-04-04 00:53:03 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2014-04-04 00:53:03 -0700 |
commit | 5cdf53e257a7e947e1e72b590eea8c1471b9be6c (patch) | |
tree | 9f8f60beae27f8ed2936faced17d2e6c036671bc | |
parent | 32938f947fe3ac8d2f7fff6242abbcfcff7cc007 (diff) | |
download | tcpdump-5cdf53e257a7e947e1e72b590eea8c1471b9be6c.tar.gz |
Define NETDISSECT_REWORKED in a bunch of files, and fix the issues it finds.
The only one it found was that routines in sigsecret.c needed to refer
to ndo->ndo_sigsecret, not just sigsecret.
-rw-r--r-- | af.c | 1 | ||||
-rw-r--r-- | bpf_dump.c | 1 | ||||
-rw-r--r-- | checksum.c | 1 | ||||
-rw-r--r-- | cpack.c | 1 | ||||
-rw-r--r-- | gmpls.c | 1 | ||||
-rw-r--r-- | gmt2local.c | 1 | ||||
-rw-r--r-- | in_cksum.c | 1 | ||||
-rw-r--r-- | ipproto.c | 1 | ||||
-rw-r--r-- | l2vpn.c | 1 | ||||
-rw-r--r-- | nlpid.c | 1 | ||||
-rw-r--r-- | oui.c | 1 | ||||
-rw-r--r-- | parsenfsfh.c | 1 | ||||
-rw-r--r-- | print-pktap.c | 1 | ||||
-rw-r--r-- | signature.c | 7 | ||||
-rw-r--r-- | util.c | 1 |
15 files changed, 18 insertions, 3 deletions
@@ -15,6 +15,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -19,6 +19,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -17,6 +17,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -27,6 +27,7 @@ * OF SUCH DAMAGE. */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -13,6 +13,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/gmt2local.c b/gmt2local.c index 2ab9c102..6958f66a 100644 --- a/gmt2local.c +++ b/gmt2local.c @@ -19,6 +19,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -35,6 +35,7 @@ * @(#)in_cksum.c 8.1 (Berkeley) 6/10/93 */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H # include "config.h" #endif @@ -13,6 +13,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -13,6 +13,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -13,6 +13,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -13,6 +13,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/parsenfsfh.c b/parsenfsfh.c index fb79333d..a86a4316 100644 --- a/parsenfsfh.c +++ b/parsenfsfh.c @@ -40,6 +40,7 @@ * Western Research Laboratory */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/print-pktap.c b/print-pktap.c index 55425330..46a187de 100644 --- a/print-pktap.c +++ b/print-pktap.c @@ -19,6 +19,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/signature.c b/signature.c index c35b7838..c3520a08 100644 --- a/signature.c +++ b/signature.c @@ -15,6 +15,7 @@ * Original code by Hannes Gredler (hannes@juniper.net) */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -128,12 +129,12 @@ signature_verify(netdissect_options *ndo, memcpy(rcvsig, sig_ptr, sizeof(rcvsig)); memset(sig_ptr, 0, sizeof(rcvsig)); - if (!sigsecret) { + if (!ndo->ndo_sigsecret) { return (CANT_CHECK_SIGNATURE); } - signature_compute_hmac_md5(pptr, plen, (unsigned char *)sigsecret, - strlen(sigsecret), sig); + signature_compute_hmac_md5(pptr, plen, (unsigned char *)ndo->ndo_sigsecret, + strlen(ndo->ndo_sigsecret), sig); if (memcmp(rcvsig, sig, sizeof(sig)) == 0) { return (SIGNATURE_VALID); @@ -19,6 +19,7 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif |