We're now a non-profit! Support open source packet analysis by making a donation.

Wireshark-dev: Re: [Wireshark-dev] Save extracted data from reassembled packets

From: Peter Smith <[email protected]>
Date: Mon, 22 Feb 2010 17:34:41 +0200
If I use print(type(wsp_pdu)) it show me userdata type which is not in the switch statement in epan/wslua/wsula_field.c. The problem is that I can't find any function that could convert this userdata type to any other usable type to work with... 

On the other hand using print("USERDATA LENGTH: " .. wsp_pdu.len) works fine and gives me apparently the correct length of the field data reassembled from multiple packets. Here is the output:
... skipped ...

On Mon, Feb 22, 2010 at 5:20 PM, Beth <[email protected]> wrote:
Is the field a boolean?  Lua support for boolean fields was fixed for 1.3.x in bug 4049.  It just got added to the 1.2 trunk and should be available in release 1.2.7.

If it's not a boolean, make sure its type is in the switch statement in epan/wslua/wsula_field.c (and the similar one in wslua_tree.c).  That's where the error message is generated.

On Mon, Feb 22, 2010 at 9:38 AM, Peter Smith <[email protected]> wrote:
I also tried to use a similar code as in previously mentioned presentation:

wsp_extractor = Field.new("wsp")
tap = Listener.new(nil,"wsp")
function tap.packet(pinfo,tvb,userdata)
local wsp_pdu =  wsp_extractor()
if wsp_pdu then

In this case I get another error:
[string "wsp.lua"]:6: FT_ not yet supported

So I am stuck for now...

Sent via:    Wireshark-dev mailing list <[email protected]xxxxxxxxx>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
            mailto:[email protected]?subject=unsubscribe