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

Which one is the best way to develop new plugin either in C or LUA.

0

I want to develop my new plugin. But I am in ambiguity either to use C or lua. Because what I have seen in past, If i choose C, It will increase my performance but it is little bit hectic to write whole plugin in C. On the other way around. If I choose LUA. It is easy to write whole plugin in LUA. but it has major performance issues. So my question is like which one is the best way to make new plugin in very effective manner???

asked 30 Jan '16, 23:07

ankit's gravatar image

ankit
65232328
accept rate: 25%


One Answer:

1

It's the tradeoff between development effort and subsequent use afterwards. Generally you'll develop a dissector once, with a little subsequent maintenance, but it will be used many times, possibly by many people, so improving performance by using C will be an effort multiplier.

It's also easier to distribute a C dissector, just create a new package installer, and also easier to contribute back to the Wireshark project as we don't really have a distribution mechanism for lua dissectors.

So, my advice would be that if you have the capabilities to develop in C, then use that. If you do use C, and you can release the code to the Wireshark project, then do so as it will then be maintained and distributed by the project itself.

answered 31 Jan '16, 01:01

grahamb's gravatar image

grahamb ♦
19.8k330206
accept rate: 22%

Thanks @grahamb. I got your point.

(31 Jan '16, 19:33) ankit