port-service-discovery

port-service-discovery is a skill for Claude Code, Codex from uphiago/recon-skills. It costs 22 tokens per session (2,764 once invoked), scanned A, original, MIT.

A network-discovery procedure that uses Nmap to identify open ports and the services behind them. Ports are numbered network entry points used by services such as databases, SSH, or FTP.

In plain words
What is it for?
Use it to scan authorized domains or IP addresses, find common and non-standard services, detect service versions, and investigate staging or backend systems.
Why use it?
It helps reveal infrastructure that a website scan may miss, while distinguishing an open port from proof of unauthorized access.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument.

Good fit Use it to scan authorized domains or IP addresses, find common and non-standard services, detect service versions, and investigate staging or backend systems.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/uphiago/recon-skills/port-service-discovery
About the project

Recon Skills is a pack of security-testing skills covering reconnaissance, web applications, APIs, authentication, vulnerability validation, cloud infrastructure, and reporting. Security professionals use it for authorized assessments of systems they own or have written permission to test. The catalogue entries are individual skills from the pack.

uphiago/recon-skills · 1,254 stars · on GitHub · hiago.sh

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add uphiago/recon-skills --skill port-service-discovery
Clone the repo
git clone --depth 1 https://github.com/uphiago/recon-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for port-service-discovery

README.md
[![agentmods](https://agentmods.dev/badge/skills/uphiago/recon-skills/port-service-discovery/github.svg)](https://agentmods.dev/skills/uphiago/recon-skills/port-service-discovery)
Your own site
<a href="https://agentmods.dev/skills/uphiago/recon-skills/port-service-discovery"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/port-service-discovery/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for port-service-discovery

Your own site · 80×15
<a href="https://agentmods.dev/skills/uphiago/recon-skills/port-service-discovery"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/port-service-discovery.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,764 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high YARA Match · line 49
    YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).
    Fix: Remove offensive tool references and exploit code. Legitimate agent skills should not contain penetration testing tools, exploit frameworks, or reconnaissance utilities.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.02764
Opus 5 $0.00011 $0.01382
Sonnet 5 $0.00004 $0.00553
Haiku 4.5 $0.00002 $0.00276

Measured 12d ago against content hash bdfa2c850572, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

port-service-discovery scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

compatibility: Requires curl, nmap, masscan
recon/port-service-discovery/SKILL.md · 256 lines

How it starts

The opening of the file, as written. The whole thing — 256 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Port & Service Discovery Skill

Use scoped Nmap discovery to identify services adjacent to web applications, including databases, remote administration, mail, caches, and non-standard API ports. An open port is an observation; service identity and unauthorized access require separate validation.

When to Use

  • Running deep-invade Phase 6 on a high-value target.
  • After surface recon shows no exploitable web vulnerabilities — pivot to infrastructure.
  • When the target is a SaaS with backend APIs on non-standard ports.
  • After discovering a staging subdomain — check for database/admin ports.

Prerequisites

  • nmap available in the execution environment.
  • Target domain or IP address.
  • For full port scan: patience (can take 10-60 minutes for all 65535 ports).

How to Run

# Fast top-100 port scan (30 seconds)
nmap -F --open -T4 TARGET -oN nmap_fast.txt

# Top 1000 ports (2-3 minutes)
nmap --top-ports 1000 --open -T4 TARGET -oN nmap_1000.txt

# Service version detection on open ports
nmap -sV -p $(grep 'open' nmap_fast.txt | cut -d/ -f1 | tr '\n' ',') TARGET

# Firewall bypass: fragment packets
nmap -f -F TARGET

Quick Reference

Port Service Finding Severity
3306 MySQL Critical (if open to internet)
27017 MongoDB Critical (if no auth)
6379 Redis Critical (if no auth)
5432 PostgreSQL High
1433 MS SQL Server High
21 FTP High (anonymous login?)
22 SSH Info (check for weak auth)
8080/8081/8082/8084 Internal APIs High (backend services exposed)
9200 Elasticsearch High (data exposure)
25/587 SMTP Medium (open relay?)
110/143/993 POP3/IMAP Info
8443 HTTPS alt (admin panels) Medium
9090 Prometheus/Cockpit Medium
3000 Grafana/Node.js dev Medium

Procedure

Step 1 — Fast Top-100 Scan

TARGET="$1"
OUTDIR="$OUTDIR/ports"
mkdir -p "$OUTDIR"

echo "[*] Fast scan (top 100 ports) on $TARGET..."
nmap -F --open -T4 --max-retries 1 --host-timeout 60s "$TARGET" -oN "$OUTDIR/${TARGET}_fast.nmap" 2>/dev/null

echo "[*] Open ports:"
grep 'open' "$OUTDIR/${TARGET}_fast.nmap" || echo "  None found"

Read the full file on GitHub · 256 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 256 lines · 22 tokens per session scan A bdfa2c850572

Subscribe to this mod's changes

port-service-discovery is a skill published in the GitHub repository uphiago/recon-skills (1,254 stars, last pushed 11d ago), licensed MIT. It adds 22 tokens to every session and 2,764 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

auditing-gcp-iam-permissions

Auditing Google Cloud Platform IAM permissions to identify overly permissive bindings, primitive role usage, service account key proliferation, and cross-project access risks using gcloud CLI, Policy Analyzer, and IAM Recommender.

xalgorix/xalgorix · 51 tokens

detecting-compromised-cloud-credentials

Detecting compromised cloud credentials across AWS, Azure, and GCP by analyzing anomalous API activity, impossible travel patterns, unauthorized resource provisioning, and credential abuse indicators using GuardDuty, Defender for Identity, and SCC Event Threat Detection.

xalgorix/xalgorix · 55 tokens

detecting-s3-data-exfiltration-attempts

Detecting data exfiltration attempts from AWS S3 buckets by analyzing CloudTrail S3 data events, VPC Flow Logs, GuardDuty findings, Amazon Macie alerts, and S3 access patterns to identify unauthorized bulk downloads and cross-account data transfers.

xalgorix/xalgorix · 63 tokens

implementing-aws-config-rules-for-compliance

Implementing AWS Config rules for continuous compliance monitoring of AWS resources, deploying managed and custom rules aligned to CIS and PCI DSS frameworks, configuring automatic remediation with SSM Automation, and aggregating compliance data across accounts.

xalgorix/xalgorix · 53 tokens

implementing-aws-security-hub-compliance

Implementing AWS Security Hub to aggregate security findings across AWS accounts, enable compliance standards like CIS AWS Foundations and PCI DSS, configure automated remediation with EventBridge and Lambda, and create custom security insights for organizational risk management.

xalgorix/xalgorix · 53 tokens

implementing-azure-defender-for-cloud

Implementing Microsoft Defender for Cloud to enable cloud security posture management, workload protection across VMs, containers, databases, and storage, configure security recommendations, and set up adaptive security controls with automated remediation.

xalgorix/xalgorix · 49 tokens