Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

add missing key_recordxfer() for transport mode AH case. mycroft@netb…

…sd.org
  • Loading branch information...
commit 61106a4f97301daa178cff2195ae2d2da87cc272 1 parent 8cb2116
itojun authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 kame/sys/netinet6/ah_input.c
View
10 kame/sys/netinet6/ah_input.c
@@ -1,4 +1,4 @@
-/* $KAME: ah_input.c,v 1.23 2000/03/25 07:23:39 sumikawa Exp $ */
+/* $KAME: ah_input.c,v 1.24 2000/03/26 23:08:59 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -77,6 +77,8 @@
#include <net/net_osdep.h>
+#define IPLEN_FLIPPED
+
#ifdef INET
extern struct protosw inetsw[];
#if defined(__bsdi__) || defined(__NetBSD__)
@@ -512,16 +514,16 @@ ah4_input(m, va_alist)
}
}
ip = mtod(m, struct ip *);
-#if 1
- /*ip_len is in host endian*/
+#ifdef IPLEN_FLIPPED
ip->ip_len = ip->ip_len - stripsiz;
#else
- /*ip_len is in net endian*/
ip->ip_len = htons(ntohs(ip->ip_len) - stripsiz);
#endif
ip->ip_p = nxt;
/* forget about IP hdr checksum, the check has already been passed */
+ key_sa_recordxfer(sav, m);
+
if (nxt != IPPROTO_DONE)
(*inetsw[ip_protox[nxt]].pr_input)(m, off, nxt);
else
Please sign in to comment.
Something went wrong with that request. Please try again.