Wireshark-bugs: [Wireshark-bugs] [Bug 11722] New: Segmentation fault when using a Lua listener
Date: Tue, 17 Nov 2015 20:05:46 +0000
Bug ID 11722
Summary Segmentation fault when using a Lua listener
Product Wireshark
Version 1.99.x (Experimental)
Hardware All
OS All
Status UNCONFIRMED
Severity Critical
Priority Low
Component Dissection engine (libwireshark)
Assignee bugzilla-admin@wireshark.org
Reporter pascal.quantin@gmail.com

Build Information:
Version 2.1.0 (v2.1.0rc0-607-gabfeb2d from master)

Copyright 1998-2015 Gerald Combs <gerald@wireshark.org> and contributors.
License GPLv2+: GNU GPL version 2 or later
<http://www.gnu.org/licenses/old-licenses/gpl-2.0.html>
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Compiled (64-bit) with Qt 5.5.0, with WinPcap (4_1_3), with libz 1.2.8, with
GLib 2.42.0, with SMI 0.4.8, with c-ares 1.9.1, with Lua 5.2, with GnuTLS
3.2.15, with Gcrypt 1.6.2, with MIT Kerberos, with GeoIP, with QtMultimedia,
with AirPcap.

Running on 64-bit Windows 10, build 10240, with locale C, with Npcap version
0.05, based on WinPcap version 4.1.3 (packet.dll version 4.1.0.2980), based on
libpcap version 1.0 branch 1_0_rel0b (20091008), with GnuTLS 3.2.15, with
Gcrypt
1.6.2, without AirPcap.
Intel(R) Core(TM) i7-4710HQ CPU @ 2.50GHz (with SSE4.2), with 8075MB of
physical
memory.


Built using Microsoft Visual C++ 12.0 build 40629

Wireshark is Open Source Software released under the GNU General Public
License.

Check the man page and http://www.wireshark.org for more information.
--
As reported by Thomas Baudelet on
https://ask.wireshark.org/questions/47671/lua-script-segmentation-fault-11-in-200rc3-on-os-x,
letting a simple lua script running with tshark ends with a segmentation fault.

Running the following script:
local ip = Listener.new("ip")
local ip_src_f = Field.new("ip.src")
function ip.packet(pinfo,tvb,tapinfo)
    if (ip_src_f() ~= nil) then
        print(tostring(ip_src_f()))
    end
end

with this command line:
tshark -q -i 1 -X lua_script:ip.lua

Ends with the following callstack:
libwireshark.dll!lua_tap_packet(void * tapdata, _packet_info * pinfo,
epan_dissect * edt, const void * data) Line 108    C
libwireshark.dll!tap_push_tapped_queue(epan_dissect * edt) Line 364    C
libwireshark.dll!epan_dissect_run_with_taps(epan_dissect * edt, int
file_type_subtype, wtap_pkthdr * phdr, tvbuff * tvb, _frame_data * fd,
epan_column_info * cinfo) Line 378    C
tshark.exe!process_packet(_capture_file * cf, epan_dissect * edt, __int64
offset, wtap_pkthdr * whdr, const unsigned char * pd, unsigned int tap_flags)
Line 3731    C
tshark.exe!capture_input_new_packets(_capture_session * cap_session, int
to_read) Line 2798    C
tshark.exe!sync_pipe_input_cb(int source, void * user_data) Line 1903    C
tshark.exe!capture() Line 2611    C
tshark.exe!main(int argc, char * * argv) Line 2318    C


You are receiving this mail because:
  • You are watching all bug changes.