diff options
author | lns <matzeton@googlemail.com> | 2022-07-28 19:59:15 +0200 |
---|---|---|
committer | lns <matzeton@googlemail.com> | 2022-07-29 18:24:42 +0200 |
commit | 8358107a9b5760b6dc9cea84c658a5d2be02c2ff (patch) | |
tree | 9dcd51e78edaa9eb1d41149242ba37fe2eb9811d /example/ndpiReader.c | |
parent | 405a52ed65c0b641b26f0571bf6a6c369c5251d7 (diff) |
Add Softether dissector.add/softether-dissector
Signed-off-by: lns <matzeton@googlemail.com>
Diffstat (limited to 'example/ndpiReader.c')
-rw-r--r-- | example/ndpiReader.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/example/ndpiReader.c b/example/ndpiReader.c index 930220801..f4c0f427a 100644 --- a/example/ndpiReader.c +++ b/example/ndpiReader.c @@ -1462,6 +1462,25 @@ static void printFlow(u_int32_t id, struct ndpi_flow_info *flow, u_int16_t threa } break; + case INFO_SOFTETHER: + if (flow->softether.ip[0] != '\0') + { + fprintf(out, "[Client IP: %s]", flow->softether.ip); + } + if (flow->softether.port[0] != '\0') + { + fprintf(out, "[Client Port: %s]", flow->softether.port); + } + if (flow->softether.hostname[0] != '\0') + { + fprintf(out, "[Hostname: %s]", flow->softether.hostname); + } + if (flow->softether.fqdn[0] != '\0') + { + fprintf(out, "[FQDN: %s]", flow->softether.fqdn); + } + break; + case INFO_FTP_IMAP_POP_SMTP: if (flow->ftp_imap_pop_smtp.username[0] != '\0') { @@ -1888,6 +1907,13 @@ static void printFlowSerialized(u_int16_t thread_id, } break; + case INFO_SOFTETHER: + ndpi_serialize_string_string(serializer, "client_ip", flow->softether.ip); + ndpi_serialize_string_string(serializer, "client_port", flow->softether.port); + ndpi_serialize_string_string(serializer, "hostname", flow->softether.hostname); + ndpi_serialize_string_string(serializer, "fqdn", flow->softether.fqdn); + break; + case INFO_FTP_IMAP_POP_SMTP: ndpi_serialize_string_string(serializer, "username", flow->ftp_imap_pop_smtp.username); |