From: Russ Combs Date: Fri, 20 Mar 2015 21:06:53 +0000 (-0400) Subject: fixed use of bound ip and tcp policy if not set in hosts X-Git-Tag: 3.0.0-233~1017 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=adbf47c71a3db031ec625f0ac196c560817a8ff8;p=thirdparty%2Fsnort3.git fixed use of bound ip and tcp policy if not set in hosts --- diff --git a/ChangeLog b/ChangeLog index 4b8677086..30b8a8078 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ Pending - build 143 +-- fixed use of bound ip and tcp policy if not set in hosts -- eliminate dedicated nhttp chunk buffer -- minor nhttp cleanup in StreamSplitter diff --git a/src/main/modules.cc b/src/main/modules.cc index 1ff0e0c9f..3e00d44cf 100644 --- a/src/main/modules.cc +++ b/src/main/modules.cc @@ -1736,10 +1736,10 @@ static const Parameter hosts_params[] = { "ip", Parameter::PT_ADDR, nullptr, "0.0.0.0/32", "hosts address / cidr" }, - { "frag_policy", Parameter::PT_ENUM, IP_POLICIES, IP_POLICY_DEFAULT, + { "frag_policy", Parameter::PT_ENUM, IP_POLICIES, nullptr, "defragmentation policy" }, - { "tcp_policy", Parameter::PT_ENUM, TCP_POLICIES, TCP_POLICY_DEFAULT, + { "tcp_policy", Parameter::PT_ENUM, TCP_POLICIES, nullptr, "tcp reassembly policy" }, { "services", Parameter::PT_LIST, service_params, nullptr, diff --git a/src/stream/ip/ip_module.cc b/src/stream/ip/ip_module.cc index 29376ab7a..e9d941266 100644 --- a/src/stream/ip/ip_module.cc +++ b/src/stream/ip/ip_module.cc @@ -110,7 +110,7 @@ static const Parameter s_params[] = { "min_ttl", Parameter::PT_INT, "1:255", "1", "discard fragments with ttl below the minimum" }, - { "policy", Parameter::PT_ENUM, IP_POLICIES, IP_POLICY_DEFAULT, + { "policy", Parameter::PT_ENUM, IP_POLICIES, "linux", "fragment reassembly policy" }, { "session_timeout", Parameter::PT_INT, "1:86400", "30", diff --git a/src/stream/stream_api.h b/src/stream/stream_api.h index 1dd31d47c..f0dfbd09e 100644 --- a/src/stream/stream_api.h +++ b/src/stream/stream_api.h @@ -60,9 +60,6 @@ "first | last | linux | old_linux | bsd | macos | solaris | irix | " \ "hpux11 | hpux10 | windows | win_2003 | vista | proxy" -#define IP_POLICY_DEFAULT "linux" -#define TCP_POLICY_DEFAULT "bsd" - class Flow; typedef int (* LogFunction)(Flow*, uint8_t** buf, uint32_t* len, uint32_t* type); diff --git a/src/stream/tcp/tcp_module.cc b/src/stream/tcp/tcp_module.cc index a0d565ee7..df6cf151f 100644 --- a/src/stream/tcp/tcp_module.cc +++ b/src/stream/tcp/tcp_module.cc @@ -114,7 +114,7 @@ static const Parameter s_params[] = { "max_pdu", Parameter::PT_INT, "1460:63780", "16384", "maximum reassembled PDU size" }, - { "policy", Parameter::PT_ENUM, TCP_POLICIES, TCP_POLICY_DEFAULT, + { "policy", Parameter::PT_ENUM, TCP_POLICIES, "bsd", "determines operating system characteristics like reassembly" }, { "reassemble_async", Parameter::PT_BOOL, nullptr, "true",