This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

Can we call a dissector plugin from another dissector plugin?

0

Folks,

As per my requirements i will have to dissect eth header for all packets of my relevant protocol. So i was wondering if we have such functionality , i may write another plugin for eth and call it from my protocol plugin.

asked 06 Aug '12, 05:09

yogeshg's gravatar image

yogeshg
41222326
accept rate: 0%


One Answer:

1

I'm not entirely sure what it is you're trying to do, but, yes dissectors/plugins can call other dissectors/plugins either directly (call_dissector()) or indirectly (caller registers a dissector table and then eventually calls dissector_try_uint() or similar and the callee registers itself for a value in that dissector table with dissector_add_uint() or similar).

answered 06 Aug '12, 06:02

JeffMorriss's gravatar image

JeffMorriss ♦
6.2k572
accept rate: 27%

thanks for your answer ,could you point me any example for this ? some plugin where this is being used

(06 Aug '12, 07:48) yogeshg

Almost all dissectors behave like this. For one example, see packet-sctp.c.

(06 Aug '12, 08:19) JeffMorriss ♦