Wireshark qmi dissector available

This past week I had to debug a issue related to a QMI-based modem, so I thought it would have been convenient to use a Wireshark qmi dissector for analyzing communication between host and modem with protocol decoding.

Wireshark qmi

Looking around the web I found Ilya Voronin’s Wireshark Dissector for Qualcomm MSM Interface (QMI) Protocol v0.1. Nice, that was what I was looking for!!

However there were a few issues:

  • Not working in Windows (I personally use Linux, but this is a requirement for many)
  • The messages list in the dissector is not really comprehensive
  • Missing TLV description: this is useful to have an idea at first glance of which kind of information is passing through

A new Wireshark qmi dissector

Due mainly to those missing features, I started working on Ilya’s (whom I thank!) code and the result is a new Wireshark QMI dissector that tries to address the described issues: it is based on the amazing work done in libqmi project, re-using their json files in order to collect all know requests and related TLVs. A Python script takes care of generating the Wireshark QMI dissector, merging their info with the dissector logic.

The result is a tool which is a lot more helpful in understanding a qmi-based modem behavior.

The script and the generated dissector are released under the GPL terms, as indicated for all the code that uses bindings to Wireshark. Files are hosted in github.

Improvements

This is just a first draft that can be really improved: currently it is not supporting indications translation and all TLVs available in libqmi common json file. As soon as I’ve a bit of spare time, I’ll try to fix those.

Not being really proficient with Python, probably also the script can be written a lot better. And, obviously, it requires a lot more of testing. All things that are in my TODO list 🙂

Hope it will be helpful and patches are welcome!