https://github.com/howie1989/ethersnoop
EtherSnoop: A portable, real-time network snooping device that captures and displays Cisco Discovery Protocol (CDP) packets, built on the W55RP20-EVB-PICO with a snazzy OLED display!
https://github.com/howie1989/ethersnoop
cdp cisco micropython w5500 w55rp20-evb-pico
Last synced: about 2 months ago
JSON representation
EtherSnoop: A portable, real-time network snooping device that captures and displays Cisco Discovery Protocol (CDP) packets, built on the W55RP20-EVB-PICO with a snazzy OLED display!
- Host: GitHub
- URL: https://github.com/howie1989/ethersnoop
- Owner: howie1989
- Created: 2024-10-16T22:23:04.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-16T23:10:28.000Z (over 1 year ago)
- Last Synced: 2025-03-28T21:45:25.653Z (about 1 year ago)
- Topics: cdp, cisco, micropython, w5500, w55rp20-evb-pico
- Language: Python
- Homepage:
- Size: 413 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# π΅οΈββοΈ **EtherSnoop** π

Welcome to **EtherSnoop** β the only detective you'll ever need to monitor where your office ports are connected like a hawk (or maybe a really tech-savvy owl π¦). Say goodbye to network mysteries and hello to **real-time Ethernet snooping**!
## π What is EtherSnoop?
EtherSnoop is a small but mighty device that captures, parses, and displays Cisco Discovery Protocol (CDP) packets over Ethernet. You know those mysterious network switches? Now, you can see exactly what they're up to!
π‘ **Built on the W55RP20-EVB-PICO** (WIZnet Ethernet + Raspberry Pi RP2040-based board), EtherSnoop monitors Ethernet connections in real-time, providing live CDP data like:
- π‘ **Switch Name** (because who doesnβt want to name-drop their network switch at parties?)
- π **Port Number** (Fa0/1, Gi0/2 β you name it, we parse it)
- ποΈ **VLAN ID** (Yes, even your VLANs have secrets, and EtherSnoop knows them!)
- π **IOS Version** (Straight from the switch firmware, like `12.2(55)EX3`)
Oh, and did we mention itβs all displayed beautifully on an OLED screen? Itβs like having a tiny window into the network world π.
## π Why Use EtherSnoop?
Whether youβre a network admin, an ethical hacker (πΆοΈ), or just someone who wants to know where things are patched in and get the basic config on that port, **EtherSnoop is your gadget**. Forget expensive packet sniffers β this oneβs cute, portable, and packs the perfect amount of nerdiness.
Hereβs what EtherSnoop can do:
- Detect when **Ethernet cables are plugged in or unplugged** (because cables seem to disappear like magic).
- Dynamically **request an IP via DHCP** and flaunt that IP on its OLED screen like it's the coolest thing ever.
- **Capture and display CDP data** β see info like "Office Switch1" on port "Fa0/5" with VLAN ID "10." (You could even put that on a t-shirt.)
- **Display the Cisco IOS version** to know exactly what software your switch is running.
- Uses **custom fonts** because, why not? Roboto Light never looked so good on an OLED screen.
## βοΈ How It Works
1. **Plug in an Ethernet cable.** EtherSnoop will request an IP via DHCP.
2. **Sit back, relax**, and let EtherSnoop capture the CDP packets.
3. **Watch the magic** on the OLED screen as EtherSnoop parses and shows you detailed info about your network switch, port, VLAN, and IOS version. (Remember, Cisco switches by default only send CDP packets every 60 seconds!)
4. **Unplug the Ethernet cable** to make it sad β just kidding, it'll patiently wait for reconnection, request a new IP, and start snooping again. It never quits. Ever. π
## π οΈ Getting Started
Ready to snoop? Letβs get you up and running in no time!
### Hardware Requirements
- **W55RP20-EVB-PICO Board** (Ethernet + RP2040 board)
- **SSD1306 OLED Screen** (128x64 pixels)
- **An Ethernet cable** (obviously!)
- **Power source**: Currently USB-powered, but you can go wireless with a battery!
### OLED Pin Connections
To hook up your OLED display (SSD1306), connect the following pins:
- **SDA (I2C Data)** to Pin **2**
- **SCL (I2C Clock)** to Pin **3**
- **VCC** to **3.3V** or **5V**
- **GND** to **Ground**
### Software Requirements
- **MicroPython** installed on your W55RP20-EVB-PICO.
- The following libraries:
- `ssd1306.py` (OLED library) from [RandomNerdTutorials](https://randomnerdtutorials.com/raspberry-pi-pico-ssd1306-oled-micropython/), though weβve modded it to work with `fdrawer`.
- `fdrawer.py` for drawing fonts from the awesome [freetype-generator](https://github.com/mchobby/freetype-generator).
- **Custom font files**: `robotl_m10.py` and its corresponding `.bin` file (Roboto Light, medium size).
### Installation
1. **Clone this repo** (you know the drill):
```bash
git clone https://github.com/YourGitHub/EtherSnoop.git
cd EtherSnoop
```
2. **Flash MicroPython** onto your W55RP20-EVB-PICO:
Use the `firmware.uf2` provided in the `firmware` folder. This is a special adaptation of the **WIZnet-ioNIC-micropython** firmware, with some tweaks for our needs (because, frankly, they left out some essential features). Flash it like you mean it!
3. **Upload all the files**:
Copy everything from root (via Thonny, rshell, or whatever you like). Your device is now ready to snoop!
4. **Plug in your Ethernet cable**, connect power, and watch EtherSnoop do its thing! β‘
### π§° Folder Structure
```
EtherSnoop/
β
βββ main.py # The brains of the operation
βββ ssd1306.py # Manages the OLED display (modded for FontDrawer)
βββ fdrawer.py # Custom font drawer library
βββ robotl_m10.py # Larger font for OLED
βββ robotl_m10.bin # Binary data for larger font
βββ firmware/ # Contains the custom MicroPython firmware
βββ firmware.uf2
```
## π Features
- **Real-time CDP Packet Parsing**: Get live details about the switch, port, VLAN, and **IOS version** β directly from your network traffic.
- **Cable Detection**: Instantly detects cable disconnection and reconnection like a pro.
- **IP Address via DHCP**: Watch your device request and show off its IP address every time it reconnects.
- **OLED Display**: Small but mighty, with custom fonts for that extra bit of flair.
## π Future Plans
- π **Battery Integration**: Soon, EtherSnoop will be untethered and completely portable!
- π¦ **Case Design**: Itβs time to give this gadget a proper home β a 3D-printed case is coming.
## π Bugs & Issues
Got bugs? We hope not, but if you do (or youβre bored and want to chat), head over to the [issues section](https://github.com/YourGitHub/EtherSnoop/issues) and let us know. EtherSnoop doesnβt like being bugged. π
## π‘ Contributing
We love contributions like a network loves packets! Feel free to submit pull requests, open issues, or even just star the repo β EtherSnoop will thank you. π
## β οΈ Disclaimer
**EtherSnoop is not responsible for any network drama it uncovers. Use it ethically, and remember β with great power comes great responsibility.** πΈοΈ
---
Thanks for checking out EtherSnoop! We hope it makes your network monitoring fun, informative, and maybe just a little bit sassy. π
Happy Snoopinβ! π΅οΈββοΈπ
P.S. β Shoutout to ChatGPT for helping write most of this README, because, letβs face it, I'm more into coding than writing whimsical README files!