Hi, im having trouble calling a dissector from another dissector. As a test, im trying to call the foo dissector, from my test dissector. The foo dissector has the following registration
Meaning its abbreviation is "foo". So, in the dissector im programing, im doing the following. I have the following global variable
This is my handoff
asked 29 Aug ‘14, 05:40 ingcpt edited 29 Aug ‘14, 09:24 grahamb ♦ |
One Answer:
In the foo dissector you need to do register_dissector("foo", dissect_foo, proto_foo); answered 29 Aug '14, 07:05 Anders ♦ Thanks! That worked like a charm! (29 Aug '14, 08:08) ingcpt Finally, i had to add, into foo (the dissector that gets called from another dissector) the line register_dissector("foo", dissect_foo, proto_foo); (29 Aug '14, 08:15) ingcpt @ingcpt, If an answer has solved your issue, don't change the title, simply click the checkmark next to the answer as that's how this site works. Please see the FAQ for more info. (29 Aug '14, 09:24) grahamb ♦ |
If foo_handle is NULL it mean that the dissector does not exist. You can check if your dissector exist by trying to find him in filter. Open Wireshark and write your dissector’s name in filter bar, green mean that Wireshark knows your dissector and red mean that he does not.
foo exists. If i run wireshark, and type foo in the filter, it turns green, yet foo_handle is still null
foo exists, and works perfectly. I made it using the guide provided by wireshark