Skip to main content
Glama
mcpcap

mcpacket

by mcpcap

analyze_tcp_anomalies

Analyze TCP traffic patterns from PCAP files to detect anomalies like unusual handshake failures or retransmission rates, providing objective metrics for network troubleshooting.

Instructions

Detect TCP traffic patterns through statistical analysis.

This tool analyzes TCP traffic to identify observable patterns without making assumptions about root causes. It provides factual metrics and pattern detection that can be used for further investigation.

Args: pcap_file: HTTP URL or absolute local file path to PCAP file server_ip: Optional filter for server IP address server_port: Optional filter for server port

Returns: A structured dictionary containing: - statistics: Comprehensive TCP metrics (handshakes, flags, RST distribution, etc.) - patterns: Observable patterns detected in the traffic - summary: High-level summary of findings

Detected pattern categories:

  • connection_establishment: Handshake success/failure rates, SYN response ratios

  • connection_termination: RST distribution, normal vs abnormal closes

  • reliability: Retransmission rates, packet loss indicators

  • connection_lifecycle: Connection state transitions

The analysis is purely observational - it reports what is seen in the traffic without attempting to diagnose specific issues like "firewall block" or "network congestion". This allows the data to be interpreted in context.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pcap_fileYes
server_ipNo
server_portNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden. It discloses the observational, non-diagnostic nature, and details return structure and pattern categories. It does not mention performance or limitations, but is transparent about its outputs and scope.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with sections for args, returns, and pattern categories, and a concluding note on observational nature. It is slightly verbose but each part adds value, earning its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has 3 parameters, an output schema, and sibling tools, the description covers inputs, outputs, and distinguishes its role. It explains return structure and pattern categories thoroughly, enabling an agent to determine appropriate use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description compensates by explaining pcap_file as HTTP URL or local path, and server_ip/server_port as optional filters. This adds necessary context beyond the schema's types and defaults, though more detail on pcap_file format could help.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool detects TCP traffic patterns through statistical analysis, and distinguishes its observational approach from sibling tools like analyze_tcp_retransmissions or analyze_tcp_connections that focus on specific aspects. It lists pattern categories, reinforcing its unique purpose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains the tool provides factual metrics for further investigation without assuming root causes, implying use for initial pattern detection rather than diagnosis. It lacks explicit when-not-to-use guidance but clearly sets context for data interpretation.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/mcpcap/mcpacket'

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