Skip to content

Conversation

grutz
Copy link
Contributor

@grutz grutz commented Mar 29, 2024

Add parsing of Meraki discovery protocol (mdp) frames

@mosajjal
Copy link
Contributor

is MDP a standard protocol? can you please provide some RFC or docs around this?

@grutz
Copy link
Contributor Author

grutz commented Mar 30, 2024

It is a proprietary Cisco protocol, much like CDP. This work was based on the Wireshark dissector.

https://github.com/wireshark/wireshark/blob/master/epan/dissectors/packet-mdp.c

@mosajjal
Copy link
Contributor

mosajjal commented Apr 6, 2024

can you please share a full pcap of some mdp traffic. be keen to study it a bit more. no issues with this PR and happy to merge it soon.

@grutz
Copy link
Contributor Author

grutz commented Apr 6, 2024

The variable testMDPFrame in mdp_test.go is a full radiotap captured packet I used for testing. You should be able to write the bytes to a file as it was created by the test_creator.py script (which also required updating to python3).

You can also review the Wireshark code and their sample capture from https://gitlab.com/wireshark/wireshark/-/issues/14912

@mosajjal mosajjal self-assigned this Apr 21, 2024
case MdpTlvUnknownBool:
offset += 2
length = int(data[offset-1])
m.Type13Bool, _ = strconv.ParseBool(string(data[offset : offset+length]))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

where does this come from? I can't see something similar in Wireshark's code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MdpTlvIP and MdpTlvUnknownBool are two types I saw when capturing MDP from a WiFi AP. The types and contents were obvious based on the ASCII.

AFAIK this protocol isn't officially documented so these types (and others) may have been added to the protocol since the Wireshark dissector was created.

@mosajjal mosajjal merged commit e126fcb into gopacket:master Oct 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants