summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormcbride <mcbride@openbsd.org>2003-10-23 23:00:37 +0000
committermcbride <mcbride@openbsd.org>2003-10-23 23:00:37 +0000
commit3bcfd27ce038b348d91a3be03278bbd1ed544c22 (patch)
treead18ae52566cc2faf9db80940dab77199ea9e0e0
parent.Xr compress 3; (diff)
downloadwireguard-openbsd-3bcfd27ce038b348d91a3be03278bbd1ed544c22.tar.xz
wireguard-openbsd-3bcfd27ce038b348d91a3be03278bbd1ed544c22.zip
We want to hash the whole md, not just the size of the pointer.
Found testing CARP between sparc and sparc64.
-rw-r--r--sys/netinet/ip_carp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c
index 60401d0ab87..37e43a06cad 100644
--- a/sys/netinet/ip_carp.c
+++ b/sys/netinet/ip_carp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_carp.c,v 1.6 2003/10/22 14:56:54 markus Exp $ */
+/* $OpenBSD: ip_carp.c,v 1.7 2003/10/23 23:00:37 mcbride Exp $ */
/*
* Copyright (c) 2002 Michael Shalayeff. All rights reserved.
@@ -189,7 +189,7 @@ carp_hmac_generate(struct carp_softc *sc, u_int32_t counter[2],
/* outer hash */
SHA1Init(&sha1ctx);
SHA1Update(&sha1ctx, opad, CARP_HMAC_PAD);
- SHA1Update(&sha1ctx, md, sizeof(md));
+ SHA1Update(&sha1ctx, md, sizeof(*md));
SHA1Final(md, &sha1ctx);
}