aboutsummaryrefslogtreecommitdiff
path: root/src/include/ndpi_typedefs.h
diff options
context:
space:
mode:
authorlns <matzeton@googlemail.com>2022-08-05 21:26:54 +0200
committerlns <matzeton@googlemail.com>2022-08-08 18:22:40 +0200
commit9939b5c30775993941a4b9afe01ddc36434afbf1 (patch)
tree6084e87015382a703fcd8b5536511d9d0728ad3e /src/include/ndpi_typedefs.h
parent523360001e4c9e64d875febd9f024daa2691c31a (diff)
Add TiVoConnect dissector. Fixes #1697.add/tivoconnect
* added static assert if supported, to complain if the flow struct changes Signed-off-by: lns <matzeton@googlemail.com>
Diffstat (limited to 'src/include/ndpi_typedefs.h')
-rw-r--r--src/include/ndpi_typedefs.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/include/ndpi_typedefs.h b/src/include/ndpi_typedefs.h
index e8b688aee..502c7fe12 100644
--- a/src/include/ndpi_typedefs.h
+++ b/src/include/ndpi_typedefs.h
@@ -1447,6 +1447,13 @@ struct ndpi_flow_struct {
u_int8_t primitive; /* GET, SET... */
u_int8_t error_status;
} snmp;
+
+ struct {
+ char identity_uuid[36];
+ char machine[48];
+ char platform[32];
+ char services[48];
+ } tivoconnect;
} protos;
/*** ALL protocol specific 64 bit variables here ***/
@@ -1524,6 +1531,17 @@ struct ndpi_flow_struct {
u_int8_t priv_data[16];
};
+#if !defined(NDPI_CFFI_PREPROCESSING) && defined(__linux__)
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
+_Static_assert(sizeof(((struct ndpi_flow_struct *)0)->protos) <= 200,
+ "Size of the struct member protocols increased to more than 200 bytes, "
+ "please check if this change is necessary.");
+_Static_assert(sizeof(struct ndpi_flow_struct) <= 904,
+ "Size of the flow struct increased to more than 904 bytes, "
+ "please check if this change is necessary.");
+#endif
+#endif
+
#define NDPI_PROTOCOL_DEFAULT_LEVEL 0
typedef struct {