Skip to main content
Glama

Wireshark MCP Server

Overview

Wireshark MCP Server bridges AI assistants and network packet analysis by exposing Wireshark/TShark functionality through the Model Context Protocol (MCP).

Instead of manually searching through packet captures, AI clients can interact with PCAP data using natural language and structured MCP tools.

This project enables:

  • PCAP investigation

  • Protocol discovery

  • Packet filtering

  • Stream analysis

  • Traffic statistics

  • Network conversation mapping

  • Live packet capture

  • AI-assisted network troubleshooting

---

Related MCP server: mcp-wireshark

โœจ Features

Feature

Description

๐Ÿ”Ž Protocol Discovery

Identify all protocols present in a PCAP

๐Ÿ“ฆ Packet Search

Search packets using Wireshark display filters

๐ŸŒ Conversation Analysis

Analyze communications between hosts

๐Ÿ”„ Stream Following

Follow TCP and UDP streams

๐Ÿ“Š Traffic Statistics

Generate protocol and traffic summaries

๐ŸŽฏ Interface Discovery

Enumerate available capture interfaces

โšก Live Capture

Capture network traffic in real time

๐Ÿค– MCP Integration

Compatible with MCP clients and AI agents

๐ŸŒ HTTP Transport

Expose tools through HTTP

๐Ÿ’ป STDIO Transport

Native MCP STDIO support

---

๐Ÿ— Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚      AI Client       โ”‚
โ”‚ ( Claude Desktop)   โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
           โ”‚ MCP
           โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Wireshark MCP Serverโ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
           โ”‚
 โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
 โ”‚                   โ”‚
 โ–ผ                   โ–ผ
TShark          Wireshark
 Engine           Engine
 โ”‚
 โ”œโ”€โ”€ PCAP Files
 โ”œโ”€โ”€ Live Capture
 โ”œโ”€โ”€ Streams
 โ”œโ”€โ”€ Conversations
 โ””โ”€โ”€ Statistics

---

๐Ÿ“ Project Structure

app/
โ”œโ”€โ”€ prompts/
โ”‚   โ””โ”€โ”€ prompts.py
โ”‚
โ”œโ”€โ”€ resources/
โ”‚   โ””โ”€โ”€ references.py
โ”‚
โ”œโ”€โ”€ tools/
โ”‚   โ”œโ”€โ”€ behavior.py
โ”‚   โ”œโ”€โ”€ conversations.py
โ”‚   โ”œโ”€โ”€ discovery.py
โ”‚   โ”œโ”€โ”€ interfaces.py
โ”‚   โ”œโ”€โ”€ live\_capture.py
โ”‚   โ”œโ”€โ”€ packets.py
โ”‚   โ”œโ”€โ”€ save\_capture.py
โ”‚   โ”œโ”€โ”€ statistics.py
โ”‚   โ””โ”€โ”€ streams.py
โ”‚
โ”œโ”€โ”€ transports/
โ”‚   โ”œโ”€โ”€ http\_transport.py
โ”‚   โ””โ”€โ”€ stdio\_transport.py
โ”‚
โ”œโ”€โ”€ utils/
โ”‚   โ””โ”€โ”€ tshark.py
โ”‚
โ”œโ”€โ”€ config.py
โ””โ”€โ”€ server.py
โ””โ”€โ”€ .env

run.py
requirements.txt

---

Requirements

Software

  • Python 3.11+

  • Wireshark

  • TShark

Verify TShark installation:

tshark -v

---

Installation

Clone the repository:

git clone https://github.com/NathcorpTraining/Wireshark-MCP.git

cd Wireshark-mcp-server

Create a virtual environment:

python -m venv venv

Activate it:

Windows:

venv\\Scripts\\activate

Linux/macOS:

source venv/bin/activate

Install dependencies:

pip install -r requirements.txt

---

Configuration

Create a .env file:

TSHARK\_PATH=C:\\\\Program Files\\\\Wireshark\\\\tshark.exe

MAX\_TIMEOUT=30

MAX\_PACKETS=10000

HTTP\_HOST=0.0.0.0

HTTP\_PORT=8080

---

Running the Server

STDIO Transport

python run.py --transport stdio

HTTP Transport

python run.py --transport http

Server endpoint:

http://localhost:8080

---

Available MCP Tools

Protocol Discovery

Discover protocols contained within a packet capture.

Search packets using Wireshark display filters.

Examples:

http

dns

tcp.port == 443

ip.addr == 192.168.1.10

Conversation Analysis

Analyze communication flows between hosts.

Stream Analysis

Follow complete TCP or UDP streams.

Traffic Statistics

Generate protocol and traffic summaries.

Interface Discovery

List available capture interfaces.

Live Capture

Capture traffic directly from selected interfaces.

Save Capture

Persist temporary capture files for later analysis.

Behavior Analysis

Analyze communication patterns and traffic behavior.

---

Example Use Cases

Incident Response

  • Investigate suspicious network activity

  • Analyze compromised host communications

  • Review attack traffic

Network Troubleshooting

  • Identify connectivity issues

  • Analyze protocol failures

  • Review packet exchanges

Security Operations

  • Investigate PCAP files

  • Review alerts with packet evidence

  • Analyze suspicious traffic patterns

Threat Hunting

  • Search for indicators of compromise

  • Review communications between hosts

  • Identify unusual traffic behavior

---

Security Notice

This tool provides packet capture and analysis capabilities.

Only capture or analyze network traffic on systems and networks for which you have explicit authorization.

The maintainers assume no responsibility for misuse of this software.

---

Roadmap

Current

  • [x] Protocol Discovery

  • [x] Packet Search

  • [x] Stream Analysis

  • [x] Conversation Analysis

  • [x] Statistics

  • [x] Live Capture

  • [x] HTTP Transport

  • [x] STDIO Transport

Planned

  • [ ] IOC Extraction

  • [ ] Threat Detection

  • [ ] Session Reconstruction

  • [ ] AI Investigation Workflows

  • [ ] Protocol Anomaly Detection

  • [ ] Export Reports

  • [ ] MITRE ATT&CK Mapping

---

๐Ÿค Contributing

Contributions, bug reports, and feature requests are welcome.

  1. Fork the repository

  2. Create a feature branch

  3. Commit your changes

  4. Open a Pull Request

---

๐Ÿ“„ License

Licensed under the MIT License.

See the LICENSE file for details.

---

โญ Support

If you find this project useful:

  • Star the repository

  • Share feedback

  • Submit feature requests

  • Contribute improvements

---

A
license - permissive license
-
quality - not tested
C
maintenance

Maintenance

โ€“Maintainers
โ€“Response time
โ€“Release cycle
โ€“Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    -
    quality
    B
    maintenance
    An MCP server that enables AI-assisted network packet analysis using Wireshark's TShark tool. It provides tools for pcap file overview, session extraction, protocol filtering, and statistical analysis through a standardized interface.
    1
    MIT

View all related MCP servers

Related MCP Connectors

  • OCR, transcription, file extraction, and image generation for AI agents via MCP.

  • MCP server exposing the Backtest360 engine API as tools for AI agents.

  • Self-hosted MCP gateway: turn any API, database or MCP server into AI connectors โ€” no code.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/NathcorpTraining/Wireshark-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server