diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2020-06-21 17:50:24 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2020-06-21 17:50:24 +0100 |
commit | feb0daf81d888e9160f9f94502de09b66f2a63fd (patch) | |
tree | b6e5c40ce2abef3da27ed50a023153f475e0ddef /net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch | |
parent | 9452a6e87b6c2c70513bc47a2470bf9f1168920e (diff) |
gentoo resync : 21.06.2020
Diffstat (limited to 'net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch')
-rw-r--r-- | net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch b/net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch new file mode 100644 index 000000000000..bcbdbc834cad --- /dev/null +++ b/net-analyzer/pmacct/files/pmacct-1.7.4-nDPI-3.2.patch @@ -0,0 +1,47 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -900,7 +900,7 @@ + [ case "$enableval" in + yes) + AC_MSG_RESULT(yes) +- PKG_CHECK_MODULES([NDPI], [libndpi >= 2.4], [ ++ PKG_CHECK_MODULES([NDPI], [libndpi >= 3.2], [ + SUPPORTS="${SUPPORTS} ndpi" + USING_NDPI="yes" + +--- a/src/ndpi/ndpi_util.c ++++ b/src/ndpi/ndpi_util.c +@@ -29,7 +29,8 @@ + + NDPI_PROTOCOL_BITMASK all; + +- struct ndpi_detection_module_struct *module = ndpi_init_detection_module(); ++ ndpi_init_prefs pm_ndpi_init_prefs = ndpi_no_prefs; ++ struct ndpi_detection_module_struct *module = ndpi_init_detection_module(pm_ndpi_init_prefs); + struct pm_ndpi_workflow *workflow = ndpi_calloc(1, sizeof(struct pm_ndpi_workflow)); + + log_notification_init(&log_notifications.ndpi_cache_full); +@@ -77,6 +78,8 @@ + NDPI_BITMASK_SET_ALL(all); + ndpi_set_protocol_detection_bitmask2(workflow->ndpi_struct, &all); + ++ ndpi_finalize_initalization(workflow->ndpi_struct); ++ + return workflow; + } + +--- a/src/ndpi/ndpi.c ++++ b/src/ndpi/ndpi.c +@@ -373,11 +373,7 @@ + + if (flow->detection_completed || flow->tcp_finished) { + if (flow->detected_protocol.app_protocol == NDPI_PROTOCOL_UNKNOWN) +-#ifdef WITH_NDPI26 +- flow->detected_protocol = ndpi_detection_giveup(workflow->ndpi_struct, flow->ndpi_flow, workflow->prefs.protocol_guess); +-#else +- flow->detected_protocol = ndpi_detection_giveup(workflow->ndpi_struct, flow->ndpi_flow); +-#endif ++ flow->detected_protocol = ndpi_detection_giveup(workflow->ndpi_struct, flow->ndpi_flow, 1, workflow->prefs.protocol_guess); + + if (workflow->prefs.protocol_guess) { + if (flow->detected_protocol.app_protocol == NDPI_PROTOCOL_UNKNOWN && !flow->guess_completed) { |