analyzing-email-headers-for-phishing-investigation

Featured

Parse and analyze email headers to trace the origin of phishing emails, verify sender authenticity, and identify spoofing through SPF, DKIM, and DMARC validation.

AI & Automation 64 stars 11 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 91/100

Stars 20%
60
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Analyzing Email Headers for Phishing Investigation ## When to Use - When investigating a suspected phishing email to determine its true origin - For verifying sender authenticity and detecting email spoofing - During incident response when a user has clicked a phishing link - When tracing the delivery path and relay servers of a suspicious email - For validating SPF, DKIM, and DMARC alignment to identify forgery ## Prerequisites - Raw email headers from the suspicious message (EML or MSG format) - Understanding of SMTP protocol and email header fields - Access to DNS lookup tools (dig, nslookup) for SPF/DKIM/DMARC verification - Email header analysis tools (MHA, emailheaders.net concepts) - Python with email parsing libraries for automated analysis - Access to threat intelligence platforms for IP/domain reputation ## Workflow ### Step 1: Extract Raw Email Headers ```bash # Export from Outlook: Open email > File > Properties > Internet Headers # Export from Gmail: Open email > Three dots > Show original # Export from Thunderbird: View > Message Source # If working with EML file from forensic image cp /mnt/evidence/Users/suspect/AppData/Local/Microsoft/Outlook/phishing_email.eml \ /cases/case-2024-001/email/ # If working with PST file, extract individual messages pip install pypff python3 << 'PYEOF' import pypff pst = pypff.file() pst.open("/cases/case-2024-001/email/outlook.pst") root = pst.get_root_folder() def extract_messages(folder, path=""): for i in ran...

Details

Author
26zl
Repository
26zl/cybersec-toolkit
Created
7 months ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Listed

analyzing-email-headers-for-phishing-investigation

Parse and analyze email headers (Received chain, Return-Path, Message-ID) to trace the true origin of a phishing email and validate SPF, DKIM, and DMARC results to confirm or rule out sender spoofing. Use when triaging a suspicious or reported email, investigating a phishing incident, or verifying whether a message's sender domain was spoofed.

0 Updated today
anxious-phyllo879
Data & Documents Listed

phishing-analysis

Analyze a reported or suspicious email end to end: Received chain and SPF/DKIM/DMARC alignment, sender and Reply-To and display-name mismatches, lookalike domains, URL and redirector analysis, QR codes, HTML smuggling, attachment triage, lure classification (BEC/invoice, credential harvest, callback/TOAD, MFA push, package delivery, HR/payroll), verdict, blast radius, and response actions. Use it whenever someone pastes headers or an .eml, says "is this phishing", "a user reported this email", "check these headers", "is this sender legit", "who else got this", asks why DMARC failed, wants a phishing triage note, or forwards a suspicious invoice, voicemail, DocuSign, MFA, delivery, or payroll-change message, even if they never use the word phishing.

0 Updated 1 weeks ago
ftrout
AI & Automation Solid

what-an-email-reveals

Investigate an email address — MX and syntactic validation, Gravatar lookup, corporate email-format inference, breach exposure, and full mail-header analysis covering the Received chain, Message-ID and SPF, DKIM and DMARC results. Use for email OSINT, verifying whether an address exists, finding accounts registered to it, guessing a company's email format, or tracing where a suspicious message actually came from. Applies to business email compromise and invoice-fraud investigation, phishing triage, vendor-payment verification, and pre-engagement research. Reference at useosint.com/skills/what-an-email-reveals.

42 Updated 1 months ago
useosint