Wireshark unable to load customized plugin
Steps followed:
Downloaded Wireshark(3.0.5) source, created build environment and build successfully without my custom dissector plugin.
Implemented custom plugin according to developer guide.
Build Wireshark with custom plugin, created xxx.dll for plugin then created installer using NSIS.
Custom Wireshark installer created and installed on system.
After installation while loading plugins, an error occurs "Couldn't load plugin 'xxx.dll :C:\Program Files (x86)\Wireshark\plugins\3.0\epan\xxx.dll':Specified module could not be found.
I verified the location where global plugins reside path "C:\Program Files (x86)\Wireshark\plugins\3.0\epan\xxx.dll" is there.
I'm unable to find root cause for the issue. If anybody has an idea, please share.
- Build on Windows 7 professional
- 32 bit installer
- Installed on windows 10, 7
Ran tests on installer found below info:
-- End stdout for command ('D:\\wsbuild32\\run\\RelWithDebInfo\\tshark.exe', '-G', 'decodes') --
-- Begin stderr for command ('D:\\wsbuild32\\run\\RelWithDebInfo\\tshark.exe', '-G', 'decodes') --
tshark: Couldn't load plugin 'xyz.dll': '\wsbuild32\run\RelWithDebInfo\plugins\3.0\epan\xyz.dll': The specified module could not be found.
-- End stderr for command ('\\wsbuild32\\run\\RelWithDebInfo\\tshark.exe', '-G', 'decodes') --
<end of output>
Test time = 44.46 sec
The test output you show seems to be running from the build, not the installer. Has your dissector ever worked on the build system?
Yes, its at build time test will open wireshark then it will load all plugins. same thing will happen if install same installer on target system.
After installation, if I open wireshark every time same issue happening , could not able to figure out what is the root cause for this issue.
I used snacc compiler to generate c++ code from asn1 schema then created messages dll ,lib by using generated c++ asn1 code, included at linking time to plugin module then perfectly generated plugin dll (xyz.dll) along wireshark source with VS2017.
Please let me know if there is any tools to find exact root cause.
Just to confirm, your dissector plugin also depends on another dll? If so, is that dll included in the Wireshark install you're creating so that it's subsequently copied to the target machine?
Yes, its depends on other dll. included to wireshark as well