diff options
author | Luca Deri <deri@ntop.org> | 2024-10-15 21:20:32 +0200 |
---|---|---|
committer | Luca Deri <deri@ntop.org> | 2024-10-15 21:21:05 +0200 |
commit | 6b6dad4fdb2e60cd2887f7d381bcab2387ba9507 (patch) | |
tree | bed0d0898743ecab5210e0247ce812fff13255c8 /src/lib/ndpi_utils.c | |
parent | ff14b369206c30711ed6fb74573ece0fee83c0df (diff) |
Implemented nDPI TCP fingerprint
Diffstat (limited to 'src/lib/ndpi_utils.c')
-rw-r--r-- | src/lib/ndpi_utils.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/ndpi_utils.c b/src/lib/ndpi_utils.c index 9b7cc387e..26efd20a2 100644 --- a/src/lib/ndpi_utils.c +++ b/src/lib/ndpi_utils.c @@ -1651,7 +1651,11 @@ int ndpi_flow2json(struct ndpi_detection_module_struct *ndpi_struct, ndpi_serialize_string_uint32(serializer, "ip", ip_version); - ndpi_serialize_string_string(serializer, "proto", ndpi_get_ip_proto_name(l4_protocol, l4_proto_name, sizeof(l4_proto_name))); + if(flow->tcp.fingerprint) + ndpi_serialize_string_string(serializer, "tcp_fingerprint", flow->tcp.fingerprint); + + ndpi_serialize_string_string(serializer, "proto", + ndpi_get_ip_proto_name(l4_protocol, l4_proto_name, sizeof(l4_proto_name))); return(ndpi_dpi2json(ndpi_struct, flow, l7_protocol, serializer)); } |