agentsclimarketplace

Cisco traffic gen

Skill bradmccloskey/claude-cisco-skills/cisco-traffic-gen

Nine Claude Code skills for Cisco network automation: backup, config gen, discovery, QoS testing, security audit.

Install
npx -y skills add bradmccloskey/claude-cisco-skills --skill cisco-traffic-gen

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • 16 days oldThe repository was created 16 days ago. New is not bad, but a brand new repository carrying a familiar-sounding name is the shape a typosquat arrives in, and there has been no time for anyone else to find a problem with it.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Generate Python scripts that create network traffic and load for testing Cisco QoS policies, bandwidth, and network performance. Use when the user wants to generate test traffic, simulate load, validate QoS markings, or stress test network links.

SKILL.md

7.7 KB, ~1.9k tokens by cl100k_base, as published. Nobody here has run it

Cisco Network Traffic Generation & QoS Testing Scripts

Write Python scripts that generate controlled network traffic for testing QoS policies and network performance. Follow these standards:

Traffic Types

TCP Traffic

  • Bulk data transfers (saturate a link to test bandwidth shaping)
  • Multiple parallel TCP streams (simulate many users)
  • Configurable payload size and duration
  • HTTP/HTTPS traffic simulation
  • FTP-like large file transfers
  • Configurable TCP window size for throughput control

UDP Traffic

  • Constant bitrate (CBR) streams at specified rates (e.g., 1 Mbps, 10 Mbps, 100 Mbps)
  • Variable bitrate (VBR) with configurable burst patterns
  • Configurable packet size (64 byte small packets to 9000 byte jumbo)
  • Adjustable packets-per-second rate
  • Multi-stream generation to different destinations

Voice (VoIP) Simulation

  • G.711 profile: 64 kbps, 160 byte payload, 20ms interval, UDP
  • G.729 profile: 8 kbps, 20 byte payload, 20ms interval, UDP
  • RTP-like headers with sequence numbers and timestamps
  • Simulate multiple concurrent calls (e.g., 50 calls = ~5 Mbps G.711)
  • Jitter injection for realistic voice patterns
  • Mark with DSCP EF (46) to test priority queue

Video Simulation

  • Constant bitrate video: 2-10 Mbps sustained UDP streams
  • Bursty video: I-frame bursts followed by smaller P/B frames
  • Configurable resolution profiles (720p ~5 Mbps, 1080p ~10 Mbps, 4K ~25 Mbps)
  • Mark with DSCP AF41 (34) to test video queue

Signaling / Control Traffic

  • Small periodic packets (SIP, SCCP-like signaling patterns)
  • Mark with DSCP CS3 (24) for call signaling class
  • Low bandwidth, latency-sensitive patterns

Scavenger / Bulk Data

  • Large sustained transfers marked DSCP CS1 (8)
  • Test that scavenger class gets deprioritized under congestion
  • Peer-to-peer style traffic patterns

Background / Best Effort

  • Mixed traffic patterns at DSCP 0 (default)
  • Web browsing simulation (short bursts, variable intervals)
  • Simulate realistic background network noise

DSCP Marking Reference

ClassDSCP NameDSCP ValuePer-Hop BehaviorTypical Use
EFEF46Expedited ForwardingVoice RTP
CS5CS540SignalingCall signaling (SIP/SCCP)
AF41AF4134Assured ForwardingVideo conferencing
AF31AF3126Assured ForwardingStreaming video
AF21AF2118Assured ForwardingTransactional data (ERP, CRM)
AF11AF1110Assured ForwardingBulk data
CS3CS324Call signalingBroadcast video
CS1CS18ScavengerBackup, P2P
DFDF0Default / Best EffortWeb, email

Traffic Profiles (Presets)

Enterprise QoS Test Suite

profiles:
  voice:
    protocol: udp
    codec: g711
    dscp: 46
    streams: 20        # 20 concurrent calls
    duration: 120s
  video:
    protocol: udp
    rate_mbps: 10
    dscp: 34
    burst_size: 15000   # bytes
    duration: 120s
  signaling:
    protocol: udp
    rate_kbps: 50
    dscp: 24
    packet_size: 200
    duration: 120s
  data_critical:
    protocol: tcp
    streams: 5
    dscp: 18
    duration: 120s
  bulk:
    protocol: tcp
    streams: 20
    dscp: 0
    duration: 120s
  scavenger:
    protocol: tcp
    streams: 10
    dscp: 8
    duration: 120s

Link Saturation Profile

# Fill a link to test queuing behavior under congestion
saturate:
  protocol: udp
  rate_mbps: 100       # adjust to match link speed
  dscp: 0
  packet_size: 1400
  duration: 60s

QoS Validation (Collect from Devices)

After generating traffic, collect QoS stats from Cisco devices to validate policy behavior:

# Interface queuing stats
show policy-map interface {interface}

# Class-map match counters
show policy-map interface {interface} | include Class|packets|bytes|rate|drops

# DSCP marking verification
show ip nbar protocol-discovery
show mls qos interface {interface} statistics

# Queue drops and tail drops
show platform hardware fed switch active qos queue stats interface {interface}

What to Validate

  • Priority queue (EF/voice): zero drops, low latency, low jitter
  • Video class (AF41): minimal drops, bandwidth guarantee met
  • Data classes (AF21/AF11): fair bandwidth allocation
  • Best effort (DF): gets remaining bandwidth after guaranteed classes
  • Scavenger (CS1): first to be dropped under congestion
  • Policing: traffic exceeding rate is remarked or dropped as configured
  • Shaping: output rate matches configured shaper

Script Architecture

# Traffic generator scripts should follow this pattern:

# 1. Parse traffic profile (YAML or CLI args)
# 2. Set up sender/receiver pairs
# 3. Open sockets with DSCP marking
# 4. Generate traffic at specified rates
# 5. Measure: throughput, packet loss, latency, jitter
# 6. Optionally collect QoS counters from devices via SSH (before/after)
# 7. Report results: per-class throughput, loss, latency, jitter

# Sender sets DSCP via socket option:
import socket
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
# Set DSCP EF (46) - shift left 2 bits for TOS field
sock.setsockopt(socket.IPPROTO_IP, socket.IP_TOS, 46 << 2)

Measurement & Reporting

Per-Stream Metrics

  • Throughput (bps) achieved vs target
  • Packet loss percentage
  • One-way latency (requires clock sync or estimation)
  • Jitter (inter-packet delay variation)
  • Out-of-order packets

QoS Policy Report

  • Per-class bandwidth allocation (expected vs actual)
  • Drop counts per class under congestion
  • Priority queue behavior (EF should have zero loss)
  • Policing/shaping conformance

Output Formats

  • Real-time console output with rich (live updating tables)
  • CSV export of per-second measurements
  • JSON summary report
  • Before/after comparison of device QoS counters

Libraries to Use

  • socket for raw TCP/UDP traffic with DSCP marking
  • scapy for crafted packets with full header control
  • asyncio for concurrent stream management
  • iperf3 Python wrapper (iperf3 library) as an alternative to raw sockets
  • netmiko for collecting QoS counters from devices
  • pyats + genie for parsing show policy-map output
  • rich for live traffic dashboards
  • numpy for jitter/latency statistics
  • yaml for traffic profile definitions
  • concurrent.futures / threading for multi-stream generation
  • time / struct for packet timestamps and sequencing

Receiver Script

Always generate a paired receiver script that:

  • Listens on the target port(s)
  • Tracks sequence numbers for loss detection
  • Measures inter-packet arrival time for jitter
  • Calculates throughput per second
  • Reports summary stats when traffic stops

Safety & Best Practices

  • Always require explicit target IP/port (never broadcast/multicast by default)
  • Include a --max-rate safety cap to prevent accidental link flooding
  • Default duration should have a sane limit (e.g., 60 seconds)
  • Support graceful stop via Ctrl+C with summary output
  • Log all traffic parameters used
  • Warn if generating traffic to production networks
  • Include --dry-run flag that shows what would be generated without sending
  • Require --confirm flag when rate exceeds 50% of a specified link speed
  • NEVER generate traffic intended for denial-of-service; these scripts are for legitimate QoS testing in controlled lab and production environments with authorization

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 327,069. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.