Evidence Acquisition & Imaging

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


Volatile vs Non-Volatile Data

Order of Volatility

Collect most volatile first β€” it disappears fastest:

PriorityData TypeVolatilityExamples
1CPU registers, cacheMillisecondsCurrent process state
2RAM / MemoryPower off = goneRunning processes, encryption keys, network connections
3Network stateSeconds-minutesARP cache, routing table, active connections
4Running processesActive only while runningProcess list, open files
5Disk (temporary)Until overwrittenTemp files, swap/pagefile
6Disk (persistent)Survives rebootFiles, logs, registry
7Backup mediaLong-termTapes, cloud backups

πŸ’‘ RAM first, disk second. Once you power off, RAM is gone forever.

Live vs Dead Acquisition

AspectLive AcquisitionDead Acquisition
System stateRunningPowered off
CapturesRAM + diskDisk only
RiskMay alter evidence slightlyNo alteration risk
When to useEncrypted drives (keys in RAM), malware analysisSafe evidence preservation

Write Blockers

What are they?

Devices that allow read-only access to storage media β€” prevents any modification to evidence during acquisition.

Types

TypeHow It WorksCost
Hardware write blockerPhysical device between evidence and forensic workstationβ‚Ή10,000–₹1,00,000
Software write blockerOS-level blocking (Linux blockdev --setro, Windows registry)Free

⚠️ Without a write blocker, simply connecting a drive can modify timestamps and metadata β€” potentially invalidating evidence.


Forensic Imaging

What is a Forensic Image?

A bit-for-bit copy (bit-stream copy) of the entire storage medium β€” including deleted files, slack space, unallocated space, and file system metadata. NOT just a file copy.

Imaging Tools

ToolTypeFormat
FTK ImagerGUI (Windows)E01 (EnCase format), DD (raw)
ddCLI (Linux)Raw image
EnCaseCommercial GUIE01
AutopsyOpen-source GUICan create and analyse images

FTK Imager Workflow

  1. Connect evidence drive (through write blocker)
  2. File β†’ Create Disk Image
  3. Select source (Physical Drive)
  4. Choose image type (E01 recommended)
  5. Set destination path
  6. FTK calculates MD5 and SHA-1 hashes
  7. Verify hashes match β†’ Image is verified

dd Command (Linux)

# Create raw image of /dev/sdb
dd if=/dev/sdb of=/forensics/evidence.dd bs=4096 status=progress
 
# Verify with hash
md5sum /dev/sdb
md5sum /forensics/evidence.dd
# Both should match exactly

Hash Verification

Why Multiple Hashes?

AlgorithmPurposeStatus
MD5Quick verification, widely used⚠️ Collision attacks exist
SHA-1Better than MD5⚠️ Deprecated
SHA-256Primary integrity verificationβœ… Secure

πŸ’‘ Record both MD5 and SHA-256 β€” MD5 for compatibility with older tools, SHA-256 for court-grade integrity proof.

When to Hash

  1. Before imaging β€” Hash the original evidence
  2. After imaging β€” Hash the image file
  3. Before analysis β€” Verify image hasn’t changed
  4. After analysis β€” Prove analysis didn’t modify evidence

Deleted File Recovery

How Deletion Works

When you delete a file, the OS doesn’t erase the data β€” it simply marks the space as β€œavailable” and removes the directory entry. The data remains until overwritten.

Key Concepts

ConceptDefinition
Allocated spaceCurrently in use by files
Unallocated spaceMarked as free β€” may contain deleted files
Slack spaceUnused portion of the last cluster allocated to a file
File carvingRecovering files based on header/footer signatures (not file system metadata)

File System Signatures

File TypeHeader (Magic Bytes)
JPEGFF D8 FF
PNG89 50 4E 47
PDF25 50 44 46
ZIP50 4B 03 04
EXE4D 5A (MZ)

RAM / Memory Acquisition

Why Memory Matters

  • Encryption keys β€” Full disk encryption keys exist in RAM
  • Running malware β€” Fileless malware lives only in memory
  • Network connections β€” Active C2 connections visible
  • User credentials β€” Passwords, tokens in process memory
  • Process information β€” What was running at capture time

Memory Acquisition Tools

ToolPlatformOutput
FTK ImagerWindows.mem file
Belkasoft RAM CapturerWindows.mem file
LiMELinux.lime file
WinPmemWindowsRaw dump

FTK Imager Memory Capture

File β†’ Capture Memory β†’ Select destination β†’ Capture

⚠️ Memory capture will alter some memory contents (the capture tool itself runs in memory). This is accepted and documented.


Evidence Storage and Handling

  • Store in tamper-evident bags for physical media
  • Use encrypted storage for digital images
  • Maintain access logs for evidence storage room
  • Backup evidence images to separate location
  • Label everything with case number, date, handler