Replies: 1 comment
-
Hey Damiano, thanks for starting this conversation. The current documentation states: 4. update: inform nDPIsrvd or other apps about a long-lasting flow, whose detection was finished a long time ago but is still active Regarding your problems/questions:
There is a difference between the "real" flow duration and the lifetime of a flow within
The value of
The idea is that other applications i.e. distributor apps may get informed of long lasting flows. Sometimes I want to dynamically activate / deactivate distributor applications. Without the
The I hope this helps to clarify things a bit. Please give me some feedback if it was or wasn't helpful, so I can adjust |
Beta Was this translation helpful? Give feedback.
-
I'm trying to understand the gory detail of "flows" lifecycle (when they "start" [NEW]; when they "finish" [END|IDLE]; what events are triggered during their life [DETECTED|NOT-DETECTED|GUESSED|DETECTION-UPDATE]; etc.).
I'm basing my reasoning on the graph reported here.
In addition to events reported in the graph, I'm registering "UPDATE" events. As I see that they are sent "...based on various conditions...", I'm interested in better understanding their role during all the "flow" lifecycle.
The main problem such UPDATE events are posing to me, related to "FLOW duration" or, better, to the time-interval between the "NEW" and "END|IDLE" events
For TCP-based flows, there are no big problems, as "END" event should be fired when a FIN or RST packet is recognized by nDPI.
Problems are for UDP-based flows, where there is NO clear indication about the latest packet to be associated to such flow. Based on what I see, even if the UDP-protocol has terminated the L7-connection, from the nDPId point of view it stay "alive" at least since some timeout occur (due to not seeing new traffic related to such flow). While waiting for such timeout, several UPDATE events are fired.
Here is an example regarding a DNS query:
Here you can see:
In the table you can see that "NEW" and "DETECTED" events are basically sent concurrently, at the very start of the flow (time in the 3rd, 4th and 5th columns are relative to "first_seen"). You can also see that those two events are generated based only on the SRC request (I guess, the very first UDP packet containing the DNS request). You can see this in the 35 byte payload of the single packet in the SRC->DST direction.
After a tiny amount of time, nDPI recognize the DNS query attributes and send the 3rd event (DETECTION-UPDATE). Here you can see that this data are captured from the DNS reply, as in the 3rd event we have 1 packet reply, with 114 byte payload.
I guess that at this time everything is completed (in terms of traffic analysis) as nothing is expected to happen later on.. And actually, event 4, 5 and 6 are UPDATE that basically add nothing the detection behaviour. Finally, at 7, an IDLE event is sent, probably 'cause some timeout have been triggered (...I guess, due to the absence of activity).
If all the above is correct, my problem is that:
So, in the end, here is my question:
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions