Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bittorrent: improve detection of UTPv1
* fix header length check: we must take into account optional extension header * it seems the check on UTPv1 header is weak only in the DATA case: wait for multiple packets only in that case The new attached trace has been captured with the Transmission client, without any other kind of traffic: ideally all the flows should be classified as Bittorrent. This is the diff of its classification with and without this patch: ``` < DPI Packets (TCP): 2029 (7.27 pkts/flow) < DPI Packets (UDP): 2259 (3.40 pkts/flow) < Confidence Unknown : 204 (flows) < Confidence Match by port : 394 (flows) < Confidence DPI (partial cache): 45 (flows) < Confidence DPI (cache) : 15 (flows) < Confidence DPI : 286 (flows) --- > DPI Packets (TCP): 2027 (7.27 pkts/flow) > DPI Packets (UDP): 1901 (2.86 pkts/flow) > Confidence Unknown : 113 (flows) > Confidence Match by port : 11 (flows) > Confidence DPI (partial cache): 139 (flows) > Confidence DPI (cache) : 16 (flows) > Confidence DPI : 665 (flows) < Unknown 1528 174586 204 --- > Unknown 1301 157680 113 34c34 < BitTorrent 6177 1025172 737 --- > BitTorrent 6404 1042078 828 ```
- Loading branch information