The Complete Production SOP: How to Deploy and Run Sublist3r OSINT Subdomain Enumeration Tool in Autonomous AI Agents
Step-by-step SOP to install and run Sublist3r OSINT Subdomain Enumeration Tool in Codex, Claude Code, and Cursor. Verified prompts, sandbox rules & fixes.
Technical Overview & Architectural Context
When autonomous AI agents are tasked with attack surface mapping or reconnaissance, they frequently hallucinate subdomains, execute unvetted network brute-forcing scripts, or trigger rate limits against target DNS servers. Without strict operational boundaries, an LLM might attempt to run uninstalled third-party binaries or parse unstructured HTML scraping artifacts, leading to corrupted context windows and silent tool execution failures. The Sublist3r OSINT Subdomain Enumeration Tool skill (`sublist3r-subdomain-enumerator`) eliminates this non-deterministic behavior. By enforcing a declarative SOP, agents leverage structured passive OSINT queries across verified search engines and SSL/TLS Certificate Transparency (crt.sh) logs without launching unauthorized active network scans. It constrains output artifacts to deterministic workspace files (`subdomains.txt`) and enforces workspace boundary safety rules before finalizing the task.
Prerequisites & Environment Requirements
Verified Search Intents & Long-Tail Queries Solved
This operational tutorial is engineered to provide deterministic solutions for these developer search queries:
Step-by-Step Execution Playbook
Local Environment Setup & SKILL.md Mounting
Create the local skill manifest directory and inject verified procedural rules into the agent runtime.
Autonomous coding assistants inspect workspace configuration paths (such as `.cursor/rules/`, `.claude/skills/`, or agent-specific root files) to ingest procedural boundaries. Mounting the `sublist3r-subdomain-enumerator` manifest informs the agent of available triggers, permission limits (`fs_write: workspace`), and expected execution workflows.
mkdir -p .agents/skills/sublist3r-subdomain-enumerator && curl -fsSL https://askills.dev/api/skills/sublist3r-subdomain-enumerator/raw -o .agents/skills/sublist3r-subdomain-enumerator/SKILL.md---
name: "sublist3r-subdomain-enumerator"
description: "Discover public subdomains across internet search engines and SSL certificate logs."
metadata:
author: "Ahmed Aboul-Ela"
version: "1.0.0"
runtime_compatibility:
- "codex"
- "claude-code"
- "cursor"
- "windsurf"
triggers:
- "enumerate subdomains sublist3r"
- "find subdomains with osint"
- "discover external attack surface"
permissions:
fs_read: true
fs_write: "workspace"
shell_exec: false
net_access: false
---
# Sublist3r OSINT Subdomain Enumeration Tool
Gathers public subdomains using Sublist3r: querying search engines and crt.sh logs.
## Execution SOP & Rules
1. Run sublist3r -d <target-domain> -o subdomains.txt to collect discovered hostnames.
2. Enumerate certificate transparency logs to uncover recently issued subdomain certificates.
3. Verify whether discovered subdomains resolve to active IP addresses or dangling DNS records.
4. Decommission or firewall forgotten test and staging environments.
Keep the SKILL.md minimal: agent tokens are preserved when passive tools emit concise, newline-delimited lists directly to workspace files rather than dumping raw tool stdout into chat context.
Ensure `shell_exec` and `net_access` are explicitly declared. Claude Code and Codex will require approval if an execution context tries to write outside of workspace boundaries.
Environment Secrets & Dependency Validation
Validate local Python binary dependencies and ensure passive OSINT APIs do not expose workspace secrets.
Sublist3r operates via Python modules (e.g., `requests`, `dnspython`). If your environment relies on optional API keys (such as VirusTotal or Shodan) for deeper enumeration, store them strictly in `.env.local` or process environment variables to prevent accidental prompt leakage into agent logs.
python3 -m pip install sublist3r dnspython requests --quiet && test -f .gitignore && grep -q ".env.local" .gitignore || echo ".env.local" >> .gitignore#!/usr/bin/env bash
set -euo pipefail
if ! command -v sublist3r &> /dev/null && ! python3 -m sublist3r -h &> /dev/null; then
echo "Error: Sublist3r is not accessible in the current Python environment."
exit 1
fi
echo "Sublist3r environment check passed."Configure the agent to invoke `python3 -m sublist3r` directly if the binary is not registered in the system `$PATH`.
Never instruct the agent to run active port scans (e.g., `-p` flag) during pure passive OSINT phases, as this triggers enterprise network alarms and IDS blocks.
Intent Matching & Trigger Invocation
Execute structured user instructions mapped directly to the skill's frontmatter trigger rules.
The runtime engine pattern-matches prompts matching 'enumerate subdomains sublist3r' or 'discover external attack surface' to the SOP defined in SKILL.md. This forces the agent to format commands strictly against the output file path rather than guessing third-party reconnaissance scripts.
claude "find subdomains with osint for staging.example.com and save to subdomains.txt"Please discover external attack surface for target domain 'staging.example.com' using passive OSINT. Follow the sublist3r-subdomain-enumerator skill rules and write all unique records to subdomains.txt.Target subdomains specifically (e.g., `api.example.com` or `dev.example.com`) to limit search engine scraping boundaries and avoid query throttling.
Search engine scrapers used by Sublist3r may trigger CAPTCHA blocks if executed repeatedly within seconds; throttle agent execution loops accordingly.
Verification, Linting & Output Quality Gate
Inspect the generated subdomain manifest for dangling CNAMEs, active DNS resolution, and syntax validity.
Once Sublist3r generates `subdomains.txt`, the agent must verify the output against the SOP checklist: confirm the file exists within workspace boundaries, validate valid FQDN format, and check for dangling records before declaring task completion.
test -s subdomains.txt && awk '/^[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/' subdomains.txt | sort -u -o subdomains.txt && wc -l subdomains.txt#!/usr/bin/env bash
set -euo pipefail
OUTPUT_FILE="subdomains.txt"
if [ ! -f "$OUTPUT_FILE" ]; then
echo "Verification failed: $OUTPUT_FILE does not exist."
exit 1
fi
COUNT=$(wc -l < "$OUTPUT_FILE" | tr -d ' ')
if [ "$COUNT" -eq 0 ]; then
echo "Verification warning: No subdomains discovered."
exit 0
fi
echo "Successfully discovered and verified $COUNT unique subdomains."Check git status to ensure `subdomains.txt` is tracked or appropriately staged according to repository security practices.
Avoid committing high-sensitivity internal reconnaissance files into public repositories without masking hostnames.
Real-World Scenario: Autonomous Attack Surface Discovery for Staging Assets
“Run an OSINT reconnaissance task to discover external attack surface for example.com. Enumerate subdomains sublist3r style, verify the outputs, and present active test or staging hostnames.”
Runtime Troubleshooting & Failure Modes
Root Cause: The agent runtime executed the tool inside an isolated Python environment where Sublist3r was not globally installed or the active virtual environment was not activated.
python3 -m pip install sublist3r || pip install git+https://github.com/aboul3la/Sublist3r.gitRoot Cause: The agent attempted to redirect output or debugging logs to a system-level directory violating the strict workspace-only file write policy.
Enforce workspace-relative output flags: sublist3r -d target.com -o ./subdomains.txtFrequently Asked Questions (Sublist3r OSINT Subdomain Enumeration Tool SOP)
Q:Can I use Sublist3r OSINT Subdomain Enumeration Tool across Codex, Claude Code, and Cursor simultaneously?
Yes. The skill conforms to the universal SKILL.md specification. Placing it in your shared project repository allows Codex, Claude Code CLI, Cursor, and Windsurf to consume the exact same triggers and SOP instructions seamlessly.
Q:How does Sublist3r OSINT Subdomain Enumeration Tool prevent context window overflow during long agent sessions?
The skill instructs the agent to write raw subdomain hostnames directly to a target file (`subdomains.txt`) instead of dumping thousands of raw log lines into conversation history, keeping context tokens reserved for critical reasoning.
Q:Does this skill require escalated root or container permissions?
No. The skill is audited with a 98/100 security score and strictly relies on user-space OSINT scraping tools and non-privileged file writes constrained directly to the active workspace directory.
Ready to equip your autonomous agent with Sublist3r OSINT Subdomain Enumeration Tool?
Copy the complete audited SKILL.md specification or download the 1-click zip bundle directly from our verified registry.