]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Merge pull request #2550 in SNORT/snort3 from ~SATHIRKA/snort3:continue_inspection_af...
authorShravan Rangarajuvenkata (shrarang) <shrarang@cisco.com>
Fri, 16 Oct 2020 19:44:41 +0000 (19:44 +0000)
committerShravan Rangarajuvenkata (shrarang) <shrarang@cisco.com>
Fri, 16 Oct 2020 19:44:41 +0000 (19:44 +0000)
Squashed commit of the following:

commit de757ccedcdc38e0b9f718bf62f64c5814abe5bc
Author: Sreeja Athirkandathil Narayanan <sathirka@cisco.com>
Date:   Wed Oct 14 14:54:00 2020 -0400

    appid: Continue appid inspection after third-party identifies an application

src/network_inspectors/appid/client_plugins/client_discovery.cc

index 43b447215f738b7deac5f3314a13cceac8c45898..9a685115cedf7e7c08d7a91451182037399df8bc 100644 (file)
@@ -348,9 +348,9 @@ bool ClientDiscovery::do_client_discovery(AppIdSession& asd, Packet* p,
          asd.is_tp_appid_available() )
     {
         entry = asd.get_odp_ctxt().get_app_info_mgr().get_app_info_entry(tp_app_id);
-        if ( !( entry && entry->client_detector
-            && entry->client_detector == asd.client_detector
-            && (entry->flags & (APPINFO_FLAG_CLIENT_ADDITIONAL | APPINFO_FLAG_CLIENT_USER) ) ) )
+        if (!entry or !entry->client_detector
+            or !(entry->flags & (APPINFO_FLAG_CLIENT_ADDITIONAL | APPINFO_FLAG_CLIENT_USER))
+            or (asd.client_detector and (entry->client_detector != asd.client_detector)))
         {
             asd.client_disco_state = APPID_DISCO_STATE_FINISHED;
             asd.set_client_detected();