summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMike Frantzen <frantzen@cvs.openbsd.org>2003-08-27 18:23:37 +0000
committerMike Frantzen <frantzen@cvs.openbsd.org>2003-08-27 18:23:37 +0000
commit0eb299bf94d58374decd545f97504682ed395970 (patch)
tree4ec0104dc7c63c617487d127b1a362d82105b0f4 /sys
parentade6d3bf4f7eb177cd08ba5bc89545de3417b070 (diff)
fix inconsistency how we handle tcpopt EOL versus how p0f v2 handles it
Diffstat (limited to 'sys')
-rw-r--r--sys/net/pf_osfp.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/net/pf_osfp.c b/sys/net/pf_osfp.c
index b7c72daa63c..c01d6de6407 100644
--- a/sys/net/pf_osfp.c
+++ b/sys/net/pf_osfp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pf_osfp.c,v 1.2 2003/08/27 16:13:21 frantzen Exp $ */
+/* $OpenBSD: pf_osfp.c,v 1.3 2003/08/27 18:23:36 frantzen Exp $ */
/*
* Copyright (c) 2003 Mike Frantzen <frantzen@w4g.org>
@@ -124,10 +124,11 @@ pf_osfp_fingerprint_hdr(const struct ip *ip, const struct tcphdr *tcp)
cnt = (tcp->th_off << 2) - sizeof(*tcp);
optp = (caddr_t)tcp + sizeof(*tcp);
for (; cnt > 0; cnt -= optlen, optp += optlen) {
- fp.fp_optcnt++;
if (*optp == TCPOPT_EOL)
break;
- else if (*optp == TCPOPT_NOP) {
+
+ fp.fp_optcnt++;
+ if (*optp == TCPOPT_NOP) {
fp.fp_tcpopts = (fp.fp_tcpopts << PF_OSFP_TCPOPT_BITS) |
PF_OSFP_TCPOPT_NOP;
optlen = 1;