summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2004-05-04 00:10:16 +0000
committerrwatson <rwatson@FreeBSD.org>2004-05-04 00:10:16 +0000
commit2f2ce5b406a2d1c463e67ddf843173792248931b (patch)
tree7a7b147525465f2fc44cfd5709891f8a6518a995
parentf42c13d96240283e7d1c6ce850608306de1085d4 (diff)
downloadFreeBSD-src-2f2ce5b406a2d1c463e67ddf843173792248931b.zip
FreeBSD-src-2f2ce5b406a2d1c463e67ddf843173792248931b.tar.gz
Assert the inpcb lock on 'last' in udp_append(), since it's always
called with it, and also requires it. Obtained from: TrustedBSD Project Sponsored by: DARPA, McAfee Research
-rw-r--r--sys/netinet/raw_ip.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/netinet/raw_ip.c b/sys/netinet/raw_ip.c
index 6668059..1953fd8 100644
--- a/sys/netinet/raw_ip.c
+++ b/sys/netinet/raw_ip.c
@@ -142,6 +142,8 @@ raw_append(struct inpcb *last, struct ip *ip, struct mbuf *n)
{
int policyfail = 0;
+ INP_LOCK_ASSERT(last);
+
#if defined(IPSEC) || defined(FAST_IPSEC)
/* check AH/ESP integrity. */
if (ipsec4_in_reject(n, last)) {
OpenPOWER on IntegriCloud