aboutsummaryrefslogtreecommitdiff
path: root/src/lib/protocols
diff options
context:
space:
mode:
authorIvan Nardi <12729895+IvanNardi@users.noreply.github.com>2022-01-08 20:40:10 +0100
committerGitHub <noreply@github.com>2022-01-08 20:40:10 +0100
commit4d27001d1dea11c759d4fa9b5a318e35b412b0c2 (patch)
tree0c703e983fea2569d30f79a59285530376ba9f5f /src/lib/protocols
parenteac3ae9ded11932c786c6adec868e09a8fd7c569 (diff)
Remove some unused fields (#1393)
Diffstat (limited to 'src/lib/protocols')
-rw-r--r--src/lib/protocols/non_tcp_udp.c2
-rw-r--r--src/lib/protocols/someip.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/protocols/non_tcp_udp.c b/src/lib/protocols/non_tcp_udp.c
index 724206704..1f71b2b72 100644
--- a/src/lib/protocols/non_tcp_udp.c
+++ b/src/lib/protocols/non_tcp_udp.c
@@ -47,7 +47,7 @@ void ndpi_search_in_non_tcp_udp(struct ndpi_detection_module_struct
return;
}
- switch (packet->l4_protocol) {
+ switch (flow->l4_proto) {
case NDPI_IPSEC_PROTOCOL_ESP:
case NDPI_IPSEC_PROTOCOL_AH:
set_protocol_and_bmask(NDPI_PROTOCOL_IP_IPSEC);
diff --git a/src/lib/protocols/someip.c b/src/lib/protocols/someip.c
index 12174a505..5ac2a4f4b 100644
--- a/src/lib/protocols/someip.c
+++ b/src/lib/protocols/someip.c
@@ -204,13 +204,13 @@ void ndpi_search_someip (struct ndpi_detection_module_struct *ndpi_struct,
//Filtering by port.
//This check is NOT a 100% thing - these ports are mentioned in the documentation but the documentation also states they haven't been approved by IANA yet, and that the user is free to use different ports.
//This is is PURELY for demo purposes and the rest of the check must be filled in later on!
- if (packet->l4_protocol == IPPROTO_UDP){
+ if (flow->l4_proto == IPPROTO_UDP){
if ((packet->udp->dest == ntohs(PORT_DEFAULT_CLIENT)) || (packet->udp->dest == ntohs(PORT_DEFAULT_SERVER)) || (packet->udp->dest == ntohs(PORT_DEFAULT_SD))) {
ndpi_int_someip_add_connection(ndpi_struct, flow);
return;
}
}
- if (packet->l4_protocol == IPPROTO_TCP){
+ if (flow->l4_proto == IPPROTO_TCP){
if ((packet->tcp->dest == ntohs(PORT_DEFAULT_CLIENT)) || (packet->tcp->dest == ntohs(PORT_DEFAULT_SERVER))) {
ndpi_int_someip_add_connection(ndpi_struct, flow);
return;