aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJunfeng Wang <drenfong.wang@intel.com>2020-03-20 18:29:53 +0800
committerJunfeng Wang <drenfong.wang@intel.com>2020-03-20 11:37:32 +0000
commit11ecf78e61442984d92d5551f83b521bc5721f87 (patch)
treebbd4d4ed2ccf374c98ccf9e5c3d808a251fe481c /src
parent277865ce3934cb9c0ff936608e9695b7c0b99003 (diff)
fix message func miss and build
Change-Id: Ifc6a3337c63d69bd4d479cf7a97974c17f809cf4 Signed-off-by: Junfeng Wang <drenfong.wang@intel.com>
Diffstat (limited to 'src')
-rw-r--r--src/dpi_api.c11
-rw-r--r--src/dpi_plugin_doc.md43
2 files changed, 10 insertions, 44 deletions
diff --git a/src/dpi_api.c b/src/dpi_api.c
index cfb5262..f4bbffd 100644
--- a/src/dpi_api.c
+++ b/src/dpi_api.c
@@ -114,10 +114,19 @@ out:
/* *INDENT-ON* */
}
+static void
+setup_message_id_table (api_main_t * am)
+{
+#define _(id,n,crc) vl_msg_api_add_msg_name_crc (am, #n "_" #crc, id);
+ foreach_vl_msg_name_crc_dpi;
+#undef _
+}
+
static clib_error_t *
dpi_api_hookup (vlib_main_t * vm)
{
dpi_main_t *dm = &dpi_main;
+ api_main_t *am = vlibapi_get_main ();
u8 *name = format (0, "dpi_%08x%c", api_version, 0);
dm->msg_id_base = vl_msg_api_get_msg_ids
@@ -135,7 +144,7 @@ dpi_api_hookup (vlib_main_t * vm)
#undef _
/* Add our API messages to the global name_crc hash table */
- dm->msg_id_base = setup_message_id_table ();
+ setup_message_id_table (am);
return 0;
}
diff --git a/src/dpi_plugin_doc.md b/src/dpi_plugin_doc.md
index fc069c0..d10cae5 100644
--- a/src/dpi_plugin_doc.md
+++ b/src/dpi_plugin_doc.md
@@ -62,46 +62,3 @@ Below is the brief design:
2). Scan SSL/TLS certificate message through hyperscan, and get application id if matched.
3). If maximum packets for this flow are checked and not found matched application, the detection will end up.
-
-## Hyperscan Installation
-
-Hyperscan can be installed from packages directly on below OS:
- Ubuntu 16.04.03
- Ubuntu 18.04 and later version
- Fedora 27 and later version
- openSUSE rolling-release Tumbleweed and later version
-
-If you cannot install Hyperscan from packages directly,
-you can build and install it from the source code.
-
-Below are steps to build and install Hyperscan on Ubuntu 16.04:
-1).Install binary prerequisites
-apt-get install cmake ragel
-apt-get install libboost-dev
-apt-get install python-dev libbz2-dev
-
-2).Download Hyperscan sources
-wget https://github.com/intel/hyperscan/archive/v5.0.0.tar.gz
-tar -xf v5.0.0.tar.gz
-
-3).Download boost headers
-wget https://dl.bintray.com/boostorg/release/1.68.0/source/boost_1_68_0.tar.gz
-tar -xf boost_1_68_0.tar.gz
-cp -r boost_1_68_0/boost hyperscan-5.0.0/include
-
-4).Build and install Hyperscan shared library.
- Just follow the instruction from here. Compilation can take a long time.
-cd hyperscan-5.0.0
-mkdir build
-cd build
-cmake -DBUILD_SHARED_LIBS=true ..
-make
-make install
-
-## Multi-Thread Support
-Since generated bytecode database is read only, you can run multiple cores
-to utilize the byte database to scale.
-
-
-
-