Hello Brian,
I have taken your code and created the plugin using my environment. I have no problem to load your plugin. Find here attached all the package. May be you could check if the created dll works with your Wireshark.
Note that I have changed the directory used to get ports.txt in the source.
May be this can help you in solving your problem.
If you send an example of capture, I can check if your dissector is working correctly with your protocol.
Regards Philippe
Date: Fri, 27 Mar 2009 00:12:52 -0400 From: oleksab@xxxxxxxxxxxxxxxxxxxxxx To: wireshark-dev@xxxxxxxxxxxxx Subject: Re: [Wireshark-dev] dissector plugin help
Olivier (wsge)
I really appreciate your quick response.
I have added the following line to my Makefile.nmake
mt.exe -manifest helen.dll.manifest - outputresource:helen.dll;2
This does indeed create a helen.dll.manifest file. I take that along with the helen.dll file and copy it into my plugins directory on another (deployment) machine.
I am still getting the error: "Couldn't load module", The specified module could not be found.
Am I missing something here..?
Attached is all my code and files in the helen.zip file. Also attached is my ports file that goes in the root of C: (c:\ports.txt)
Some things have changed from my last e-mail.
I downloaded the source wireshark-1.1.2-SVN-26844. I built wireshark using the Visual Studio 2005 Command prompt. I put my plugin in place and it too builds fine and runs great on the development machine. I have no problems running my software and dissecting packets.
But when I copy the helen.dll.manifest and the helen.dll to another machine I get "Couldn't load module", The specified module could not be found.
Any thoughts..?
Thank you very much for your help.
Brian
wsgd wrote:
I think the answer is into your first mail : http://www.wireshark.org/lists/wireshark-dev/200902/msg00013.html
To include the manifest inside the dll :
mt.exe -manifest <dll_name>.dll.manifest - outputresource:<dll_name>.dll;2
Also, into proto_reg_handoff_helen, if you have many ports, you are calling many times : - data_handle = find_dissector("data"); ---> useless - helen_handle = create_dissector_handle(dissect_helen, proto_helen); ---> I do not think it works
Olivier
Brian Oleksa a écrit :
Olivier (wsgd)
I fixed the problem in the code that you found. Thanks again for finding this. I tested it on the development machine and it worked great.!!
I then took the created helen.dll file and dropped it on a deploy machine that is running the same version of wireshark that I developed against only to find that it "Couldn't load module", The specified module could not be found.
Any suggestions or thoughts on this one..?
Thanks again for all your help.
Brian
wsgd wrote:
Hello,
Into proto_reg_handoff_helen, you try to fopen("/root/ports", "r"), which certainly fails on windows, so you call exit(1).
Olivier
Brian Oleksa a écrit :
Wiresharkers
I have followed these instructions: (I used both of these as one was more clear than the other on certain tasks). http://www.codeproject.com/KB/IP/custom_dissector.aspx http://www.wireshark.org/docs/wsdg_html_chunked/ChSetupWin32.html
I am using:
MSVC_VARIANT=MSVC2008EE
I then verify_tools, install libraries (nmake -f Makefile.nmake setup), distclean and build wireshark with *NO *problems.
I then test wireshark and it does indeed start up with *NO *problems.
I then create my wireshark dissector code, make files etc.* (NOTE: This runs on Linux FC-9 with NO problems. If I take the attached helen.zip file go to my linux box, do a make install and put the helen.so file in the plugin directory everything works fine.) *
I drop my code in place. C:\wireshark\plugins\helen The name of my wireshark dissector is called helen.
From the C:\wireshark\plugins\helen directory I do the following: nmake -f Makefile.nmake distclean nmake -f Makefile.nmake all
I have NO errors and it does indeed create a *helen.dll* file. (Which I believe is what I want).
I drop this helen.dll file in the following directory: C:\wireshark\wireshark-gtk2\plugins\1.1.4HELEN-DISSECTOR
I start up wireshark (by invoking wireshark.exe) the splash screen appears for a second than disappears. So it never start up. It does not provide me with a error message.
I tried the following work around (click on link below) but had NO luck. http://www.wireshark.org/lists/wireshark-dev/200902/msg00013.html
So at this point...I am stuck.
Attached is all my code (helen.zip). Again, this same code works on my fedora core 9 box.
Any help is greatly appreciated.
Thank you
Brian Oleksa Software Developer Dark Corner Software
------------------------------------------------------------------------
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe
Votre correspondant a choisi Hotmail et profite d'un stockage quasiment illimité. Créez un compte Hotmail gratuitement !
|
Attachment:
helen_bis.7z
Description: application/7z-compressed