Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Wireshark dissector for protocols implemented #1

Open
3 of 5 tasks
smarek opened this issue Jul 28, 2020 · 7 comments
Open
3 of 5 tasks

Create Wireshark dissector for protocols implemented #1

smarek opened this issue Jul 28, 2020 · 7 comments
Labels
help wanted Extra attention is needed

Comments

@smarek
Copy link
Member

smarek commented Jul 28, 2020

This is related issue, not core issue, however I'm not skilled in Lua, so I'm gonna need some help here

Guide on how to import sub-classes in wireshark dissectors https://mika-s.github.io/wireshark/lua/dissector/2018/12/18/creating-a-wireshark-dissector-in-lua-5.html

Also it might be easier to develop the dissector as binary plugin in C/C++ instead of Lua, due to wireshark Lua limitations

@smarek smarek added the help wanted Extra attention is needed label Jul 28, 2020
@smarek
Copy link
Member Author

smarek commented Jul 29, 2020

Lua runtime modified for 5.2 provided in cdc83b0

@KOLANICH
Copy link

KOLANICH commented Aug 7, 2020

BTW, can the dissector generator either be a separate project from Hytera Homebrew Bridge, or even better a part of KSC (wireshark dissectors target is a long awaited item in the wishlist).

@smarek
Copy link
Member Author

smarek commented Aug 7, 2020

@KOLANICH It should be, kaitai-to-wireshark is not really generator, as it does not reflect upon KSC definitions and hierarchy, and what I'm coding here is not generator either

if the KSC Lua runtime will be compatible with Lua 5.2, it should be doable, however I'm really unqualified in Lua, and it seems to me, that the dissector must be generated directly from KSC definitions, and it's not possible to just wrap around generated Lua classes.

@KOLANICH
Copy link

KOLANICH commented Aug 7, 2020

It largery depends on the API Wireshark exposes and on availibility of "debug" code generation for lua target.

More precisely, debug API allows to get offsets for each seq member. I have built upon "debug" API a tool generating tags for WxHexEditor

@smarek
Copy link
Member Author

smarek commented Aug 9, 2020

I might have dive depper into debug, because I hoped for some kind of object introspection/reflection on java/python to generate the final lua, instead of using the generated lua and wrapping around them

@smarek
Copy link
Member Author

smarek commented Aug 11, 2020

But seeing the tests Translator, it might be easier to write similar Wireshark translator instead

@smarek
Copy link
Member Author

smarek commented Oct 17, 2020

I've just updated ksy definitions and Lua runtime as well, so now it should be quite easy to finish that, but I'd still appreciate any help on that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants