ReconX is an end-to-end automated external security assessment framework designed for professional penetration testers, bug bounty hunters, and enterprise red teams.
It performs deep recon, enumeration, vulnerability scanning, OSINT, exposure discovery, and reporting across multiple targets at scale.
- Automated subdomain enumeration
- Passive + active DNS enumeration
- Public-facing IP discovery
- IP range mapping & validation
- Live web app detection
- Landing page screenshots
- Technology stack detection
- Full TCP/UDP port scan
- Version fingerprinting
- Automated sitemap discovery
- Automated OWASP Top-10 web scans
- Network-level vulnerability scanning
- Component/CVE scanning (SBOM-based)
- Sensitive-data/OSINT exposure detection
- Per-target HTML report
- Aggregated structured raw outputs (
raw/) - Screenshots folder
recon-framework/
β
βββ main.py
βββ targets.txt
β
βββ modules/
β βββ subdomains.py
β βββ dns_enum.py
β βββ ip_discovery.py
β βββ web_scanner.py
β βββ screenshot.py
β βββ tech_detect.py
β βββ port_scan.py
β βββ sitemap.py
β βββ owasp_scan.py
β βββ network_vuln.py
β βββ cve_scan.py
β βββ osint_scan.py
β βββ report.py
β
βββ output/
βββ raw/
βββ report/
import asyncio
import os
from modules.subdomains import run_subdomain_enum
from modules.dns_enum import dns_enumerate
from modules.ip_discovery import discover_ips
from modules.web_scanner import detect_live_web
from modules.screenshot import take_screenshots
from modules.tech_detect import detect_tech_stack
from modules.port_scan import run_port_scan
from modules.sitemap import generate_sitemap
from modules.owasp_scan import run_owasp_scan
from modules.network_vuln import run_network_vuln_scan
from modules.cve_scan import run_cve_scan
from modules.osint_scan import run_osint_checks
from modules.report import build_report_html
OUTPUT_DIR = "output/"
TARGET_FILE = "targets.txt"
async def process_target(target):
print(f"\n[+] Processing: {target}")
target_dir = os.path.join(OUTPUT_DIR, "raw", target.replace("://","_"))
os.makedirs(target_dir, exist_ok=True)
# Stage 1 β Subdomain Discovery
subs = await run_subdomain_enum(target, target_dir)
# Stage 2 β DNS Enumeration
dns_data = await dns_enumerate(subs, target_dir)
# Stage 3 β IP/Host Discovery
ips = await discover_ips(subs, target_dir)
# Stage 4 β Web Application Detection
live_web = await detect_live_web(ips, target_dir)
# Stage 5 β Screenshots
await take_screenshots(live_web, target_dir)
# Stage 6 β Tech Stack Detection
tech = await detect_tech_stack(live_web, target_dir)
# Stage 7 β Port Scan (TCP/UDP + Version)
scan_data = await run_port_scan(ips, target_dir)
# Stage 8 β Sitemap generation
await generate_sitemap(live_web, target_dir)
# Stage 9 β OWASP Top 10 web scan
owasp_findings = await run_owasp_scan(live_web, target_dir)
# Stage 10 β Network Vulnerability Scan
net_vulns = await run_network_vuln_scan(ips, target_dir)
# Stage 11 β CVE/component scanning
cve = await run_cve_scan(live_web, target_dir)
# Stage 12 β OSINT + Sensitive Data Exposure
osint = await run_osint_checks(target, target_dir)
# Stage 13 β Build HTML Report
await build_report_html(target, target_dir)
async def main():
with open(TARGET_FILE, "r") as f:
targets = [t.strip() for t in f.readlines() if t.strip()]
tasks = [process_target(t) for t in targets]
await asyncio.gather(*tasks)
if __name__ == "__main__":
asyncio.run(main())Each module uses real tools:
- subfinder, amass, dnsx,
- httpx, whatweb,
- nmap, naabu,
- nuclei, nikto,
- osv-scanner, trivy,
- waybackurls, shodan, github-dorks, etc.
I will show the complete module code for all:
import asyncio
import subprocess
import os
async def run_subdomain_enum(domain, outdir):
outfile = os.path.join(outdir, "subdomains.txt")
cmds = [
f"subfinder -silent -d {domain}",
f"amass enum -passive -nocolor -d {domain}",
f"assetfinder --subs-only {domain}"
]
with open(outfile, "w") as f:
for cmd in cmds:
proc = await asyncio.create_subprocess_shell(
cmd,
stdout=asyncio.subprocess.PIPE,
stderr=asyncio.subprocess.DEVNULL
)
out, _ = await proc.communicate()
f.write(out.decode())
os.system(f"sort -u {outfile} -o {outfile}")
return open(outfile).read().splitlines()import asyncio, os
async def dns_enumerate(subs, outdir):
infile = os.path.join(outdir, "subdomains.txt")
outfile = os.path.join(outdir, "dns.txt")
cmd = f"cat {infile} | dnsx -resp-only -silent > {outfile}"
await asyncio.create_subprocess_shell(cmd)
return outfileimport asyncio, os
async def discover_ips(subs, outdir):
outfile = os.path.join(outdir, "ips.txt")
cmd = f"cat {outdir}/dns.txt | cut -d ' ' -f2 | sort -u > {outfile}"
await asyncio.create_subprocess_shell(cmd)
return open(outfile).read().splitlines()import asyncio, os
async def detect_live_web(ips, outdir):
outfile = os.path.join(outdir, "live_web.txt")
cmd = f"cat {outdir}/ips.txt | httpx -silent -status-code -title -tech-detect > {outfile}"
await asyncio.create_subprocess_shell(cmd)
return open(outfile).read().splitlines()import asyncio, os
async def take_screenshots(targets, outdir):
cmd = f"cat {outdir}/live_web.txt | aquatone -out {outdir}/screenshots"
await asyncio.create_subprocess_shell(cmd)import asyncio, os
async def detect_tech_stack(targets, outdir):
outfile = os.path.join(outdir, "tech.txt")
cmd = f"cat {outdir}/live_web.txt | whatweb --log-verbose={outfile}"
await asyncio.create_subprocess_shell(cmd)
return outfileimport asyncio, os
async def run_port_scan(ips, outdir):
outfile = os.path.join(outdir, "ports.txt")
cmd = f"naabu -list {outdir}/ips.txt -p - -silent | tee {outfile}"
await asyncio.create_subprocess_shell(cmd)
nmap_out = os.path.join(outdir, "nmap.xml")
nmap_cmd = f"nmap -sV -sC -p- -oX {nmap_out} -iL {outdir}/ips.txt"
await asyncio.create_subprocess_shell(nmap_cmd)
return outfileimport asyncio, os
async def generate_sitemap(targets, outdir):
cmd = f"cat {outdir}/live_web.txt | katana -silent -o {outdir}/sitemap.txt"
await asyncio.create_subprocess_shell(cmd)import asyncio, os
async def run_owasp_scan(targets, outdir):
cmd = f"nuclei -l {outdir}/live_web.txt -t nuclei-templates/ -o {outdir}/nuclei.txt"
await asyncio.create_subprocess_shell(cmd)
return outdir + "/nuclei.txt"import asyncio, os
async def run_network_vuln_scan(ips, outdir):
cmd = f"nessuscli scan run --targets {outdir}/ips.txt --output {outdir}/nessus_report"
return cmd # (Run manually if needed)import asyncio, os
async def run_cve_scan(live_targets, outdir):
cmd = f"trivy fs . --format json --output {outdir}/cve.json"
await asyncio.create_subprocess_shell(cmd)
return outdir + "/cve.json"import asyncio, os
async def run_osint_checks(domain, outdir):
cmd = f"github-dorks -q '{domain}' -o {outdir}/osint.txt"
await asyncio.create_subprocess_shell(cmd)
return outdir + "/osint.txt"import os
async def build_report_html(target, outdir):
html = f"""
<html>
<head><title>Recon Report - {target}</title></head>
<body>
<h1>Recon Report for {target}</h1>
<h2>Subdomains</h2>
<pre>{open(outdir + '/subdomains.txt').read()}</pre>
<h2>Technologies</h2>
<pre>{open(outdir + '/tech.txt').read()}</pre>
<h2>Open Ports</h2>
<pre>{open(outdir + '/ports.txt').read()}</pre>
<h2>Nuclei Findings</h2>
<pre>{open(outdir + '/nuclei.txt').read()}</pre>
<h2>CVE Scan</h2>
<pre>{open(outdir + '/cve.json').read()}</pre>
<h2>OSINT Exposures</h2>
<pre>{open(outdir + '/osint.txt').read()}</pre>
</body>
</html>
"""
with open(outdir + "/report.html", "w") as f:
f.write(html)
return outdir + "/report.html"sudo apt update
sudo apt install python3 python3-pip nmap chromium-browserReconX depends on industry-standard tools:
go install -v github.com/projectdiscovery/subfinder/v2/cmd/subfinder@latest
go install -v github.com/tomnomnom/assetfinder@latest
go install -v github.com/OWASP/Amass/v3/...@latest
go install -v github.com/projectdiscovery/dnsx/cmd/dnsx@latestgo install -v github.com/projectdiscovery/httpx/cmd/httpx@latest
go install -v github.com/michenriksen/aquatone@latest
sudo apt install whatwebgo install -v github.com/projectdiscovery/naabu/v2/cmd/naabu@latest
sudo apt install nmapgo install github.com/projectdiscovery/katana/cmd/katana@latestgit clone https://github.com/projectdiscovery/nuclei-templates /opt/nuclei-templates
go install -v github.com/projectdiscovery/nuclei/v3/cmd/nuclei@latestsudo apt install trivypip install github-dorksexample.com
company.com
test.org
One entry per line; domains/IP ranges supported.
python3 main.pyThe framework will:
- Read all targets
- Execute all modules
- Store results inside
output/raw/<target>/ - Generate HTML reports
output/raw/company.com/
β
βββ subdomains.txt
βββ dns.txt
βββ ips.txt
βββ live_web.txt
βββ screenshots/
βββ tech.txt
βββ ports.txt
βββ nmap.xml
βββ sitemap.txt
βββ nuclei.txt
βββ cve.json
βββ osint.txt
βββ report.html
output/report/
βββ company.com_report.html
βββ example.com_report.html
Below is a simplified pipeline diagram:
TARGET β Subdomain Enum
β DNS Enum
β IP Discovery
β Live Web Detection
β Screenshots
β Tech Stack Detection
β Port Scan (TCP/UDP)
β Sitemap Crawl
β OWASP Top 10 Scan
β Network Vuln Scan
β CVE Scan
β OSINT Exposure Scan
β HTML Report
Each module runs independently so the toolkit is:
- scalable
- easy to extend
- easy to debug
- reusable for future projects
Add a new module:
- Create a file in
modules/new_module.py - Write an async function:
async def run_new_feature(target, outdir):
...
return results- Import and call it in
main.pypipeline.
Run:
export PATH=$PATH:~/go/binInstall Chromium:
sudo apt install chromium-browserChange in port_scan.py:
nmap -T4Update path in config:
NUCLEI_TPL = "/opt/nuclei-templates/"This toolkit can reveal sensitive internal and external attack surfaces.
Use only on systems you own or have explicit written permission for.