Network & Email Forensics

πŸ“ Concept Note β€” DFIR Unit IV | Source: MCA Sem III Syllabus


Network Forensics

What to Capture

  • Full packet capture (PCAP) β€” Complete packet data including payloads
  • NetFlow data β€” Metadata only (source/dest IP, ports, bytes, duration)
  • Firewall logs β€” Allow/deny decisions
  • IDS/IPS logs β€” Detected attacks
  • Proxy logs β€” Web browsing activity

Where to Capture

LocationMethodWhat You See
Network TAPHardware device that copies all trafficComplete, unfiltered traffic
SPAN portSwitch mirrors traffic to monitoring portSelected switch traffic
EndpointWireshark on hostOnly that host’s traffic
Inline deviceIPS, proxyFiltered/inspected traffic

Forensic Analysis with Wireshark

Identifying C2 Traffic:

  • Regular interval connections (beaconing) β€” e.g., every 60 seconds
  • Connections to unusual ports
  • DNS queries with encoded subdomains (DNS tunnelling)
  • HTTPS to self-signed certificates

Identifying Data Exfiltration:

  • Large outbound transfers to unknown IPs
  • DNS queries with unusually long subdomains (data encoded in DNS)
  • Encrypted traffic to non-standard ports
  • Upload volume >> download volume

Identifying Lateral Movement:

  • SMB connections between workstations (unusual)
  • RDP connections from unexpected sources
  • PsExec / WMI remote execution patterns

Email Forensics

Email Header Analysis

Headers reveal the true path an email took:

Return-Path: <sender@domain.com>
Received: from mail.domain.com (10.0.0.5) by mx.recipient.com
    with SMTP; Wed, 02 Jul 2025 10:30:00 +0530
Received: from [192.168.1.10] by mail.domain.com
    with SMTP; Wed, 02 Jul 2025 10:29:55 +0530
From: "CEO" <ceo@company.com>
To: finance@company.com
Subject: Urgent Wire Transfer
Date: Wed, 02 Jul 2025 10:29:50 +0530
Message-ID: <unique-id@domain.com>
X-Mailer: Custom Mailer 1.0

Reading Headers (Bottom to Top)

Headers are added at each hop β€” read from bottom to top to trace the path:

  1. Bottom Received: = originating server
  2. Each subsequent Received: = next hop
  3. Top Received: = recipient’s mail server

Identifying Spoofing

  • From: field says ceo@company.com
  • But Received: headers show originating IP is 185.220.101.1 (not company’s mail server)
  • SPF check: Does the sending IP match company.com’s SPF record?
  • DKIM check: Is the cryptographic signature valid?

SPF/DKIM/DMARC

CheckPurposeResult Meanings
SPFVerifies sending IP is authorisedpass / fail / softfail / none
DKIMVerifies email content integrity (crypto signature)pass / fail
DMARCPolicy combining SPF + DKIMreject / quarantine / none

Cloud Forensics Challenges

ChallengeDescription
Shared responsibilityCloud provider owns infrastructure; you own data/config
JurisdictionData may be stored in different countries
Evidence acquisitionCan’t physically seize cloud servers
Multi-tenancyYour data shares infrastructure with others
VolatilityAuto-scaling may destroy instances with evidence
API-based collectionMust use cloud APIs (AWS CloudTrail, Azure Activity Logs)

Conceptual Evidence Sources

CloudLog SourceWhat It Shows
AWSCloudTrailAPI calls (who did what)
AzureActivity LogsResource changes
GCPAudit LogsAdmin activity

Mobile Forensics (Introduction)

iOS vs Android

AspectiOSAndroid
EncryptionFull disk, default since iOS 8Full disk, varies by manufacturer
AcquisitionDifficult without passcodeEasier with USB debugging enabled
BackupiTunes/iCloud backupsADB backups
App dataSandboxed, encryptedVaries, some in SQLite

Common Mobile Artifacts

  • Call logs, SMS/MMS messages
  • App data (WhatsApp, Telegram databases)
  • GPS/location data
  • Photos with EXIF metadata (GPS coordinates, timestamps)
  • Browser history
  • Wi-Fi connection history

Dark Web & Encryption Challenges

Dark Web

  • Accessed via Tor browser
  • .onion domains β€” not indexed by search engines
  • Challenges: anonymity, jurisdiction, encrypted communications
  • Investigators may need specialised training and legal authority

Encryption Challenges

  • Full Disk Encryption (FDE): If powered off, data is inaccessible without key
  • Solution: Live acquisition (capture RAM β†’ extract encryption keys)
  • End-to-end encrypted messaging: Content not available from provider
  • VPN/Tor: Harder to trace network activity