diff options
author | Simone Mainardi <mainardi@ntop.org> | 2021-09-15 17:49:47 +0200 |
---|---|---|
committer | Simone Mainardi <mainardi@ntop.org> | 2021-09-15 17:49:47 +0200 |
commit | 978c9cfda376d008aa4801205f3dd887638d5053 (patch) | |
tree | fced4ccd35b1f51af321c724ca8ea25b74b082dc | |
parent | 0eb7a0388c4549ebbf8cd7a10d398088005cc2de (diff) |
Adds instructions to update flow risks in ntopng
-rw-r--r-- | src/include/ndpi_typedefs.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/include/ndpi_typedefs.h b/src/include/ndpi_typedefs.h index dc5e49655..9f58075d8 100644 --- a/src/include/ndpi_typedefs.h +++ b/src/include/ndpi_typedefs.h @@ -67,6 +67,15 @@ typedef enum { - https://github.com/ntop/ntopng/blob/dev/scripts/lua/modules/flow_risk_utils.lua - ndpi_risk_enum (in python/ndpi.py) - ndpi_known_risks (ndpi_main.c) + + To make sure the risk is also seen by ntopng: + 1. Add a new flow alert key to the enum FlowAlertTypeEnum in include/ntop_typedefs.h + 2. Add the very same flow alert key to the table flow_alert_keys in scripts/lua/modules/alert_keys/flow_alert_keys.lua + 3. Add the risk to the array risk_enum_to_alert_type in src/FlowRiskAlerts.cpp + - To initialize .alert_type use the flow alert key added in 1. and an AlertCategory + - To initialize .alert_lua_name use a unique string + + Example: https://github.com/ntop/ntopng/commit/aecc1e3e6505a0522439dbb2b295a3703d3d0f9a */ typedef enum { NDPI_NO_RISK = 0, |