summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorAlexander Bluhm <bluhm@cvs.openbsd.org>2011-02-06 13:08:50 +0000
committerAlexander Bluhm <bluhm@cvs.openbsd.org>2011-02-06 13:08:50 +0000
commit59d3f979967df46c4ef324b551f81f4c4635fe8c (patch)
tree90d6e8ad6cca7244425813dfdbb4426574066774 /sys
parent3302c093117803384e72262451cf7e2ddfc73468 (diff)
pf_test() and pf_test6() drop IPv4-ICMP6 and IPv6-ICMP packets. Do
not do the same check in pf_test_rule() again. ok henning
Diffstat (limited to 'sys')
-rw-r--r--sys/net/pf.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/net/pf.c b/sys/net/pf.c
index 59fd5fd3659..b1bc6be378e 100644
--- a/sys/net/pf.c
+++ b/sys/net/pf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pf.c,v 1.723 2011/02/05 17:29:05 bluhm Exp $ */
+/* $OpenBSD: pf.c,v 1.724 2011/02/06 13:08:49 bluhm Exp $ */
/*
* Copyright (c) 2001 Daniel Hartmeier
@@ -2776,8 +2776,6 @@ pf_test_rule(struct pf_rule **rm, struct pf_state **sm, int direction,
break;
#ifdef INET
case IPPROTO_ICMP:
- if (pd->af != AF_INET)
- break;
icmptype = pd->hdr.icmp->icmp_type;
icmpcode = pd->hdr.icmp->icmp_code;
state_icmp = pf_icmp_mapping(pd, icmptype,
@@ -2793,8 +2791,6 @@ pf_test_rule(struct pf_rule **rm, struct pf_state **sm, int direction,
#endif /* INET */
#ifdef INET6
case IPPROTO_ICMPV6:
- if (af != AF_INET6)
- break;
icmptype = pd->hdr.icmp6->icmp6_type;
icmpcode = pd->hdr.icmp6->icmp6_code;
state_icmp = pf_icmp_mapping(pd, icmptype,