Skip to content

woww: Auto generate implementation from wowm

gtker requested to merge gtker/wireshark:woww-autogenerate-all into master

Progresses #17481.

This PR auto generates the Wireshark definitions from the wowm files at the wow_messages repo. wowm is a DSL I'm working on that is also used for generating a library and documentation. The auto generator for Wireshark is located in the same repo.

I tried to split it into distinct commits that still compile and run correctly.

I realize that just dumping a gazillion LOC on you isn't very fun, but the alternative of creating smaller PRs over weeks/months would probably just stretch out the pain for everybody involved. There are 607 distinct messages, so even adding 20 per week would still take over half a year, and it would require reviewers to review 30 PRs that are really just the same thing. This would also just unnecessarily slow down the rate at which people got a useful dissector and add a significant administrative burden on everybody involved.

Autogenerating the defintions has significant benefits since updates to the wowm DSL will automatically update the docs, libraries and wireshark dissector without any additional information. Trying to use the wireshark implementation for debugging was pretty severely hampered by having message definitions not match the wireshark definitions, which led to significant pain.

Future work will include:

  • better and more accurate wowm definitions.
  • deduplication of identical cases.
  • Support for 2.4.3 and 3.3.5 as originally discussed in #11398 (closed). This is now possible since I don't have to manually implement everything myself but can use community additions from the wowm definitions.

The support for 2.4.3 is relatively easy, since the header deduction is functionally the same as for 1.12. 3.3.5 changes the header encryption system to use RC4. I believe it is possible to crack the cipher in a useful time frame because of vulnerabilities discovered in RC4 and knowledge of the data being encrypted.

Let me know if you want any changes. :)

Merge request reports