I want to add FT_FRAMENUM for the direct link to frame. But it seems for some reason wireshark is not recognizing the hfinfo and throwing exception DISSECTOR_ASSERT_NOT_REACHED from proto_tree_add_uint. From my analysis I found wireshark is not recognizing hf_tmp_test_tmp in the above code. Please help me with this. asked 12 Jan ‘17, 02:10 chirag |
One Answer:
I can run your sample code without any issue with Wireshark 2.2.3. Are you developing an internal dissector, or a plugin? If it is a plugin, are you compiling it against Wireshark 2.2.3 source code? The ftenum enumeration found in epan/ftypes/ftypes.h changes between Wireshark major releases, so FT_FRAMENUM will not have the same value depending on the branch used. answered 13 Jan '17, 06:01 Pascal Quantin Hi Pascal, I am developing plugin. I am compiling it using the latest wireshark libraries (source code git cloned). currently I am using it one a 32-bit wireshark 2.2.3 version for windows. (16 Jan '17, 03:01) chirag Hi Pascal, It seems you are right, the ftypes which is used by the wireshark I downloaded from the internet is different then the one I am compiling with . I calculated the offset and instead of FT_FRAMENUM i had put FT_IPXNET which is right after it, and it worked as FT_FRAMENUM. Any idea on how to check the installed wireshark ftypes.h file? (16 Jan '17, 04:43) chirag What you should do is ensure you are compiling against the Wireshark version you intend to use. So if you want to run Wireshark 2.2.X stable release, you need to clone master-2.2 branch and not master branch (that corresponds to Wireshark 2.3.0 development builds). Wireshark internal APIs are not stable between major releases and you will face many weird issues if you do not follow my advice. Then compile your plugin source code as usual. (16 Jan '17, 06:00) Pascal Quantin Hi Pascal, thanks a lot for the help, I changed the libraries to match with the installed versions and all problems are gone. (16 Jan '17, 06:18) chirag As the problem is solved, please accept the answer for the benefit of other users by clicking the checkmark icon next to the answer. (16 Jan '17, 06:32) Pascal Quantin |
What is the exact assertion you’re getting? And what version are you using?
I am using version 2.2.3 and I am getting Assertion: DISSECTOR_ASSERT_NOT_REACHED.
Sorry, I meant exactly which
DISSECTOR_ASSERT_NOT_REACHED
? Usually when an assertion fires it gives you a file and line number.Hi Jeff it is not showing which dissector and the line number…it just shows DISSECTOR_ASSERT_NOT_REACHED.
One more thing when I replaced FT_FRAMENUM with FT_UINT56, BASE_DEC then it shows the number but as it is just integer link is not there.