]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Merge pull request #2319 in SNORT/snort3 from ~OSHUMEIK/snort3:clean_up to master
authorBhagya Tholpady (bbantwal) <bbantwal@cisco.com>
Wed, 8 Jul 2020 18:27:07 +0000 (18:27 +0000)
committerBhagya Tholpady (bbantwal) <bbantwal@cisco.com>
Wed, 8 Jul 2020 18:27:07 +0000 (18:27 +0000)
Squashed commit of the following:

commit 2eb1f7e3a2c2ea700c335eddd1f007df9a1e60c3
Author: Oleksii Shumeiko <oshumeik@cisco.com>
Date:   Thu Jul 2 15:32:21 2020 +0300

    binder: delete obsolete network_policy parsing code

src/network_inspectors/binder/bind_module.cc

index 233bee4cbacaffcf0d26ae45ea9e19af84e854d1..93755f83da03a9d48371e5c9f0276be9785019fc 100644 (file)
@@ -36,7 +36,6 @@ using namespace std;
 #define FILE_KEY ".file"
 #define INSPECTION_KEY ".inspection"
 #define IPS_KEY ".ips"
-#define NETWORK_KEY ".network"
 
 THREAD_LOCAL BindStats bstats;
 
@@ -121,9 +120,6 @@ static const Parameter binder_use_params[] =
     { "ips_policy", Parameter::PT_STRING, nullptr, nullptr,
       "use ips policy from given file" },
 
-    { "network_policy", Parameter::PT_STRING, nullptr, nullptr,
-      "deprecated, ignored by binder" },
-
     { "service", Parameter::PT_STRING, nullptr, nullptr,
       "override automatic service identification" },
 
@@ -268,9 +264,6 @@ bool BinderModule::set(const char* fqn, Value& v, SnortConfig*)
     else if ( v.is("ips_policy") )
         add_file(v.get_string(), IPS_KEY);
 
-    else if ( v.is("network_policy") )
-        add_file(v.get_string(), NETWORK_KEY);
-
     else if ( v.is("name") )
     {
         work->use.name = v.get_string();
@@ -326,15 +319,6 @@ bool BinderModule::end(const char* fqn, int idx, SnortConfig* sc)
             return true;
         }
 
-        // FIXIT-D: remove this when network_policy binding is deleted from
-        // the binder's options
-        if ( work->use.type == NETWORK_KEY )
-        {
-            delete work;
-            work = nullptr;
-            return true;
-        }
-
         if ( unsplit_nets && work->when.split_nets )
             split_nets_warning();