Project

General

Profile

Actions

Feature #3243

open

ndndump: follow TCP stream

Added by Junxiao Shi over 8 years ago. Updated over 5 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Start date:
Due date:
% Done:

0%

Estimated time:
6.00 h

Description

Currently, ndndump is able to recognize NDN packets on IPv4/IPv6 TCP tunnels only if an NDN packet is aligned to the front of a TCP segment.

If a TCP segment contains more than one NDN packets, all but the first NDN packet would be discarded.

If a NDN packet spans multiple TCP segments, it would be discarded, and "TLV length exceeds buffer length" error may appear.

ndndump should follow the TCP stream in the general case, and parse NDN packets in order.

In case of packet loss or reordering, a fallback heuristic of "looking for NDN packet aligned to the front of a TCP segment" can be used.


Files

20151007120415.pcap (3.56 KB) 20151007120415.pcap Junxiao Shi, 10/07/2015 12:50 PM
20151007120415.tlv (3.3 KB) 20151007120415.tlv Junxiao Shi, 10/07/2015 12:50 PM

Updated by Junxiao Shi over 8 years ago

Under low traffic, NDN packets between NFDs typically align to the front of TCP segments.

However, this is not the case under high traffic, such as high definition video.

Attached is part of a tcpdump capture that shows this phenomenon, and the extracted payload that can be successfully parsed by ndn-dissect.

Actions #2

Updated by Alex Afanasyev over 8 years ago

I'm kind of inclined towards rejecting this issue. We may want to print out partial packet information, but following actual TCP stream requires a non-trivial implementation of tcp stream reassembly.

Moreover, a similar functionality is already available in wireshark (and its command-line version tshark) with LUA NDN filter.

Actions #3

Updated by Junxiao Shi over 8 years ago

Is there any harm in doing TCP reassembly?

Following TCP stream isn't so hard: a hashtable keyed by <next-tcp-sequence, src-endpoint, dst-endpoint>.

I did TCP reassembly for RPC messages in 180 lines of C code: nfsdump:commit:677b7e1f5b4cef742f046fb8c98765841f885364.

Actions #4

Updated by Davide Pesavento over 5 years ago

  • Subject changed from dump: follow TCP stream to ndndump: follow TCP stream
Actions

Also available in: Atom PDF