Home

Awesome

🔍 Wireshark dissectors for Ethereum devp2p protocols

This repo contains a set of network protocol dissectors for Ethereum that you can load into the widely popular Wireshark to begin inspecting Ethereum traffic.

Currently we support the UDP-based discovery protocol, but support for the RLPx Wire protocol and the ETH subprotocol are in the works.

<p align="center"> <img src="https://github.com/ConsenSys/devp2p-dissectors/raw/web/assets/ethereum-discovery-demo.gif" alt="Ethereum discovery dissector demo"> </p>

Here are the features currently supported by the Ethereum Discovery dissector (we're working on more):

Protocol version support

ProtocolVersionStatusNotes
discoveryv4
discoveryv5🚧v5 is work-in-progress in clients. Refer to issues and PRs labelled discv5.
wirev1🚧wip branch: devp2p-wire

Table of contents

Build & run

We're working to enable building the plugin separately from Wireshark. In the meantime, you will need to clone the Wireshark repo.

  1. Go to the Wireshark repo and clone it.
  2. Set up your build environment. The steps vary depending on your OS.
  1. Run a plain Wireshark build to ensure all is OK. In macOS, it looks like this:
$ cd ${WIRESHARK_SRC}
$ # check out the latest 2.6 tag (could be higher)
$ git checkout wireshark-2.6.2
$ mkdir ../wireshark-ninja
$ cd ../wireshark-ninja
$ cmake -G Ninja ../wireshark
$ ninja
  1. Clone this repo onto a separate directory.
  2. Symlink the root of this repo under ${WIRESHARK_SRC}/plugins/epan/ethereum, i.e. ln -s ${THIS_REPO} ${WIRESHARK_SRC}/plugins/epan/ethereum.
  3. Modify the ${WIRESHARK_SRC}/CMakeLists.txt file to add the plugins/epan/ethereum directory under the PLUGIN_SRC_DIRS variable, i.e.:
  ...
	set(PLUGIN_SRC_DIRS
		plugins/epan/ethercat
		plugins/epan/ethereum
		plugins/epan/gryphon
    ...
  1. Delete all contents under wireshark-ninja, and run the full Wireshark build again repeating step 3.
  2. If all went well, you should be able to run the resulting Wireshark executable inside the wireshark-ninja/run directory.
  3. Happy dissecting!

Team

Ordered alphabetically by surname.

Why this project?

In the Protocol Engineering Groups and Systems team (PegaSys) at ConsenSys, we specialise in the low-level, deep aspects of the Ethereum technology. Some of the challenges we tackle are: scalability, secrecy, modularity, finality, permissioning, etc.

To perform our job we need tooling to x-ray into different parts of the system. One of those parts is the networking layer. No central authority exists in public chain Ethereum, hence all communication is peer-to-peer (P2P), which gives rise to both RPC-style and gossip-like communication patterns we need full insight of during development, research and testing.

devp2p is the name of the networking subsystem of Ethereum, along with its collection of core protocols on top of which subprotocols like ETH, Whisper, Swarm, Light Ethereum, etc. are layered.

Wireshark is a popular tool for network packet analysis. Users can initiate network dumps and navigate through a wealth of packet data via its powerful GUI. The architecture of Wireshark is modular, and it revolves around the concept of dissectors: components capable of decoding a concrete protocol, which can be in use at any layer of the OSI model.

Unfortunately no Wireshark dissectors exist yet for Ethereum devp2p protocols. This project changes that.

About PegaSys

<a href="https://pegasys.tech/?utm_source=github&utm_medium=source&utm_campaign=ethereum-dissectors" rel="nofollow"><img src="https://github.com/ConsenSys/devp2p-dissectors/raw/web/assets/logo.png" alt="PegaSys logo" data-canonical-src="https://github.com/ConsenSys/devp2p-dissectors/raw/web/assets/logo.png" width=450></a>

PegaSys’ mission is to build blockchain solutions ready for production in business environments. We are committed to open source, and are creating a framework for collaborative innovation for the public-chain community and leading enterprises.

Our team is composed of engineers leading in the areas of big data processing, applied cryptography, open source computing, cloud services, and blockchain development.

Learn more about PegaSys.

License

This project is licensed under GPLv2.