ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
April 17th, 2024 | 14:30-16:00 SGT (UTC+8) | Online

Wireshark-users: [Wireshark-users] Lua: dump segment data into file

Date: Fri, 30 Sep 2011 14:13:49 +0200
Hi all,

I try to dump the segement data (tcp payload) of tcp connections into files. Somehow I seem to miss the point. Neither tvb related functions nor some fields allow me to get my hands on the raw segment data. Also the IO functions only accept numbers or strings. I'm at this since quite a while now and start getting frustrated.

Any clues on how to read and write the raw data during a tap?

The nearest I got was :write(tostring(tvb:range():bytes())) but this does not give the raw data.

I really appreciate any help.

Many thanks in advance!

BR,

Jörg