Wireshark

  • Riverbed Technology
  • WinPcap
the world's foremost network protocol analyzer
  • Wireshark
    • About
    • Download
    • Blog
  • Get Help
    • Ask a Question
    • FAQs
    • Documentation
    • Mailing Lists
    • Online Tools
    • Wiki
    • Bug Tracker
  • Develop
    • Get Involved
    • Developer's Guide
    • Browse the Code
    • Latest Builds

Wireshark-dev: [Wireshark-dev] problems with accessing pinfo, tvb in C, pinfo and tvb are passed from lua

Date Index Thread Index Other Months All Mailing Lists
Date Prev Date Next Thread Prev Thread Next


From: yami <yamisoe@xxxxxxxxx>
Date: Tue, 9 Dec 2008 17:46:25 +0800

Hi dev,

Here is my story: my C dissector stores some information in pinfo->private_data, then it calls my lua dissector. I also wrote a C dynamic library which can be called by lua dissector, so that lua dissector can extract information from pinfo->private_data. The whole process can be ilustrated by:

C dissector ---calls---> lua dissector
     ----loadlib---> C function extract data from pinfo->private_data
         ----return-data----> lua dissector

Unfortunately the definition of Pinfo in epan/wslua/wslua.h was changed from rev. 25844 to rev. 25845 [1]. Due to this change, my code make wireshark crash.

My question is: how can we prevent this kind of thing in the futhure? By adding a function (or macro) like this (?)

packet_info* wslua_pinfo(Pinfo pinfo)
{
    return pinfo->ws_pinfo;
}

Thanks!

----

[1] See bug 2453: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2453
  • Follow-Ups:
    • Re: [Wireshark-dev] problems with accessing pinfo, tvb in C, pinfo and tvb are passed from lua
      • From: Balint Reczey
  • Prev by Date: Re: [Wireshark-dev] Dissecting Protocol within Decrypted SSL Packets
  • Next by Date: Re: [Wireshark-dev] problems with accessing pinfo, tvb in C, pinfo and tvb are passed from lua
  • Previous by thread: Re: [Wireshark-dev] Dissecting Protocol within Decrypted SSL Packets
  • Next by thread: Re: [Wireshark-dev] problems with accessing pinfo, tvb in C, pinfo and tvb are passed from lua
  • Index(es):
    • Date
    • Thread

Wireshark and the "fin" logo are registered trademarks of the Wireshark Foundation