MAILFORGE · BLUE TEAM
Your email domain, hard to impersonate.
MailForge audits a domain’s anti-spoofing protection (SPF, DKIM, DMARC, DNSSEC, MTA-STS…), grades it A to F and generates the records and plan to lock it down.
- domain grade
- A–F
- DNS and TLS checks
- 9
- screens in the guide
- 3
- parts explained
- 9
What it is and what it is for
MailForge is a defensive suite against email spoofing: it analyses a domain’s anti-spoofing protection (SPF, DKIM, DMARC, DNSSEC, MX, STARTTLS, MTA-STS, TLS-RPT and BIMI), computes a 0–100 score with an A–F grade and simulates which of eight attack vectors would succeed.
It then generates the configuration to close the gaps: ready-to-paste SPF, DMARC and MTA-STS TXT records, Postfix with OpenDKIM configuration, a DKIM key rotation guide and a phased DMARC rollout (none → quarantine 25 % → 100 % → reject) that does not break legitimate senders.
The engine is standard-library Python, with its own DNS client (RFC 1035, EDNS0 and DNSSEC OK) that falls back from UDP to TCP and DNS-over-HTTPS. It includes an interactive CLI, a local React web console, an API, JSON/HTML reports, a monitor that rescans periodically and, for authorised drills on your own mailboxes, a composer and sending through swaks.
When to use it
Auditing your mail domain
Find out in 30 seconds whether someone could send mail that looks like yours, and why.
Rolling out DMARC without breaking anything
Follow the phased plan and review reports before reaching p=reject.
Hardening the server
Copy the DNS records and Postfix + OpenDKIM configuration generated for your domain.
Watching for changes
The monitor warns when the score changes after a provider or DNS change.
How it works
Robust DNS resolution
core/dnsx.py queries over UDP, falls back to TCP and, behind restrictive NAT, to DoH (dns.google or Cloudflare) with retries.
Standards parsers
core/spf, dkim and dmarc implement RFC 7208, 6376 and 7489.
Scoring and vectors
core/scorer.py weighs the controls and simulates the eight vectors (direct spoof, subdomains, DKIM replay, TLS downgrade…).
Hardening and drills
core/hardening.py generates the configuration; core/swaks_bridge.py builds the .eml and runs swaks with an argument list, no shell.
What changes on pwn3d.es
- On pwn3d.es the tool is explained with a visual guide: its interface recreated in CSS, screen by screen, with each part numbered and explained.
- pwn3d.es neither runs nor hosts the tool: to use it there are its official site and repository, always at their latest version.
Installation and usage
Installation
git clone https://github.com/D1se0/emailSpoofingTool.git
cd emailSpoofingTool
pip3 install -r requirements.txt # solo rich (opcional)
./mailforge.sh # Linux/macOS · mailforge.bat en Windowscd server && npm install && npm start # API + web → http://localhost:8787
cd ../web && npm install && npm run buildUsage
python3 mailforge.py analyze gmail.com # análisis completo + score
python3 mailforge.py analyze gmail.com --save # + informe en reports/
python3 mailforge.py dkim gmail.com # caza de selectores DKIM (~60)
python3 mailforge.py spf gmail.com
python3 mailforge.py dmarc gmail.com
python3 mailforge.py dnssec example.com
python3 mailforge.py tls gmail.com # MX/STARTTLS/MTA-STS/TLS-RPT
python3 mailforge.py vectors gmail.com # 8 vectores con probabilidadpython3 mailforge.py harden midominio.com # registros DNS + Postfix/OpenDKIM
python3 mailforge.py rollout midominio.com # plan DMARC por fases
python3 mailforge.py verify --file mensaje.eml # verifica DKIM de un mensaje
python3 mailforge.py report midominio.com html
python3 mailforge.py watch midominio.com 300 # monitor cada 5 minReal examples
$ python3 mailforge.py analyze gmail.com tabla SPF / DKIM / DMARC / DNSSEC / MTA-STS score 0–100 con letra A–F 8 vectores de ataque simulados · nada se envía, solo consultas DNS
Summarised output described in the README.
Stack and dependencies
- Python3.9+
- Standard-library engine: own DNS, RFC parsers and verify-only RSA/Ed25519
- rich
- Interactive CLI with tables and bars (optional)
- Node18+
- Local API in server/ (:8787)
- React18
- Web console with live analysis
- swaks
- SMTP sending for authorised drills
git · repository code
Explore the repository
Related tools
Defensive integration: it analyzes and generates configuration, but does not include the original repository's Spoof Lab, swaks delivery or self-test. STARTTLS cannot be probed from the browser and is shown as unverifiable.