appneta / tcpreplay

Pcap editing and replay tools for *NIX and Windows - Users please download source from
http://tcpreplay.appneta.com/wiki/installation.html#downloads
1.17k stars 268 forks source link

[Bug] VLAN deletion option --enet-vlan=del does not work with Linux Cooked Capture #791

Closed msi3na closed 1 year ago

msi3na commented 1 year ago

I am trying to delete the VLAN layer from PCAPs with Linux Cooked Capture. It seems ineffective: input and output PCAPs are the same. The option works well with PCAPs having regular VLAN tags over Ethernet.

Command tcprewrite --enet-vlan=del -i pcap_vlan.pcap -o pcap_vlan1.pcap

Attached input and output file Archive 2.zip

Tried on both versions below:

-- MAC OS homebrew tcprewrite version: 4.4.3 (build git:v4.4.3) Copyright 2013-2022 by Fred Klassen - AppNeta Copyright 2000-2012 by Aaron Turner The entire Tcpreplay Suite is licensed under the GPLv3 Cache file supported: 04 Compiled against libdnet: 1.14 Compiled against libpcap: 1.10.1 64 bit packet counters: enabled Verbose printing via tcpdump: enabled Fragroute engine: enabled

-- Ubuntu 20.4 LTS tcprewrite version: 4.4.1 (build git:v4.4.1) Copyright 2013-2022 by Fred Klassen - AppNeta Copyright 2000-2012 by Aaron Turner The entire Tcpreplay Suite is licensed under the GPLv3 Cache file supported: 04 Not compiled with libdnet. Compiled against libpcap: 1.9.1 64 bit packet counters: enabled Verbose printing via tcpdump: enabled Fragroute engine: disabled

image

fklassen commented 1 year ago

Even though this looks quite a bit like Ethernet packets, SLL is just enough different that it needs a major implementation. For now, packet edits are not supported for SLL and SLL2. This is enhancement is shelved for the forseeable future.