I am writing a lua dissector for a propietary protocol. The packets include embedded .png files that I would like to write to an output folder named "ImageDump_<capturefilename>". Is there a way in lua to query the name of the current capture file being loaded? asked 04 Aug '15, 18:42 mfbaker edited 04 Aug '15, 18:44 |
One Answer:
Not that I know of. Are you doing this in tshark, or wireshark, or both? If you're doing this in Wireshark, then you should probably not do it automatically but instead only when the user tells you to, like through a menu command - in which case you could have them type a folder name to use in a dialog window when they select that menu item. (i.e., have the Lua script add a menu item called "Export PNG...", and have that create a window for text input of the folder name) If you're doing this in tshark, then you should probably still not do it automatically, but only if they load your script with the " answered 04 Aug '15, 19:09 Hadriel |
It is only for wireshark. I did add a menu item to only write the image files if a menu item is selected to do so:
I am writing a wireshark lua dissector for a propietary protocol, and am still looking for an answer to the question I posted about a month ago. Is there a way in lua to query the name of the current capture file being loaded? The packets include embedded .png files that I would like to write to an output folder named “ImageDump_<capturefilename>”.