A source-cited reference library 399 modules · 19 subdomains · 5 domains
Research Library
Disk and Memory Forensics

Cybersecurity / Dfir

Disk and Memory Forensics

The preservation and analysis of volatile and non-volatile digital evidence — from RAM chips to hard drive platters — to reconstruct events, attribute actions, and support legal proceedings.

Executive brief

Disk forensics acquires and examines storage media while maintaining integrity via write blockers and hash validation. Memory forensics captures volatile state before power loss. Together they reveal execution artifacts, network connections, and file remnants critical to incident response.

Overview and context

Digital evidence exists in two primary states: persistent storage (hard drives, SSDs, USB drives) and volatile memory (RAM, CPU registers). Disk forensics focuses on preserving the exact state of storage devices at seizure, preventing alteration through hardware write blockers and creating bit-for-bit images for analysis. Memory forensics captures the transient state of running systems — including open network sockets, decrypted passwords, and rootkit artifacts — before power removal destroys this evidence. Both disciplines require strict adherence to chain-of-custody procedures and validation through cryptographic hashing.

The field emerged alongside early computer crime investigations in the 1980s, evolving from simple file recovery to sophisticated timeline reconstruction and anti-forensic evasion detection. Modern practitioners navigate challenges like full-disk encryption, virtual machines, and cloud storage while relying on foundational principles: volatile evidence is most fragile, storage media preserves historical states, and every examination step must be documented and repeatable. Standards such as NIST SP 800-86 provide rigorous frameworks for acquisition, analysis, and reporting, ensuring consistency across law enforcement, corporate, and academic environments.

A portable forensic write blocker device connected to a laptop
Write blocker in use — hardware device preventing commands from reaching storage media during imaging. Photograph via Wikimedia Commons.

Technical and feature breakdown

Imaging & Anti-Forensics

Forensic imaging creates a verifiable duplicate of storage media using write blockers that prevent commands from reaching the device. Tools like dd with hardware interfaces produce bit-for-bit copies stored in raw formats (E01, AFF4) or plain .dd files. Anti-forensics techniques attempt to thwart imaging through hidden partitions, firmware attacks, or interface manipulation; defenders counter with write blockers, hash verification before/after imaging, and interface authentication via USB serial numbers. Validation relies on cryptographic hashes (SHA-256) compared against the original media, ensuring the image is an exact replica unaltered by the acquisition process.

Close-up of RAM chips on a memory module
Memory chip detail — volatile storage where active processes, network connections, and encryption keys reside. Photograph via Wikimedia Commons.

Memory Acquisition & Analysis

Volatile memory capture requires specialized tools that bypass the operating system to read physical RAM directly, avoiding reliance on potentially compromised software agents. Hardware solutions like PCIe DMA cards retrieve memory contents via direct memory access, while software tools execute at high privilege levels to minimize interference. Acquisition methods include cold boot attacks (exploiting data remanence in chilled RAM drops) and FireWire exploitation, though modern defenses like memory encryption and secure boot reduce their effectiveness. Analysis reconstructs artifacts such as process lists, network connections, and injected code by parsing operating system structures — a process complicated by packing, encryption, and kernel-level hiding employed by advanced malware.

The table sets the acquisition methods the page names against how each works and what reduces its effectiveness.

MethodHow it worksWhat reduces it
PCIe DMA cardReads physical memory directly, bypassing the operating systemHardware restrictions on direct memory access
High-privilege software toolRuns at a privilege level high enough to read memoryA compromised or interfering operating system
Cold bootExploits data remanence in chilled memory chipsMemory encryption and secure boot
FireWire accessUses the bus to read memory without the host's cooperationInterface and firmware hardening

Four routes into volatile memory and their countermeasures; no route is universal, so the tool follows the target.

Filesystem & Registry Analysis

Filesystem examiners parse on-disk structures to recover allocated and deleted files, interpret metadata (timestamps, permissions), and reconstruct user activity. Common formats like NTFS, FAT32, ext4, and APFS each require specialized parsers that handle journaling, compression, and encryption layers. Registry analysis focuses on the Windows hierarchical database storing system and user configuration; hives like SYSTEM, SOFTWARE, and NTUSER.DAT reveal auto-start locations, installed software, and user-specific settings. Timelining correlates filesystem modifications with registry changes to establish sequences of execution, while keyword searching and hash sets filter known good or malicious files.

Deleted-Data Recovery

When files are deleted, their data often remains intact until overwritten by new storage allocation. Carving scans raw data for file signatures (headers/footers) to recover fragmented or orphaned content independent of filesystem metadata. Techniques like header/footer carving, structure-based carving, and statistical carving target specific file types (JPEG, PDF, ZIP) or generic binary patterns. Success depends on fragment size, contiguous block availability, and avoidance of recent writes; solid-state drives complicate recovery due to wear-leveling and TRIM commands that erase blocks proactively. Investigators prioritize imaging immediacy to maximize recovery potential before background processes overwrite evidence.

The table separates the carving approaches the page names by what each one uses to find recoverable content.

ApproachWhat it usesTypical target
Header and footer carvingKnown file signatures at the start and end of dataFormats with distinctive boundaries, such as JPEG and PDF
Structure-based carvingThe internal layout a valid file must followStructured documents and archives such as ZIP
Statistical carvingPatterns and probabilities in the raw dataGeneric binary content without a reliable signature

Three carving routes and their assumptions; success still depends on fragment size, contiguous blocks, and how little has been written since deletion.

The imaging example, annotated

This document's working example — kept exactly as drafted, and safe: it demonstrates a basic disk imaging workflow using standard Unix utilities — sits on the right, and it is included because it illustrates the write-blocker principle and hash validation, which are foundational to trustworthy evidence. Read against the design above, the snippet shows one half of the acquisition process: dd if=/dev/sdb of=image.dd bs=4M creates a bit-for-bit copy, and sha256sum image.dd generates a fingerprint for verification. In this toy example, the image is produced without altering the source drive, and verification confirms fidelity. Real-world imaging adds hardware write blockers, progress monitoring, and concurrent hashing to ensure integrity throughout the operation.

The example also shows the importance of block size: larger blocks (e.g., 4MB) reduce system call overhead and improve throughput on modern interfaces, while smaller blocks increase latency but may be necessary for damaged media. The second code block on the right is the verifier's side of that fight: the real checks that confirm an image matches the source, and the one-line answer to the question every acquisition begins with — are the hashes identical before accepting the image as evidence.

The imaging example — creating a bit-for-bit copy with dd and verifying integrity via SHA-256; annotated in the text.

# Example: forensic imaging workflow (educational only)
#!/bin/bash
# Variables
SOURCE_DEVICE="/dev/sdb"
IMAGE_FILE="/forensic/images/exhibit1.dd"
HASH_FILE="/forensic/images/exhibit1.dd.sha256"

# Acquire image with 4MB block size
dd if="$SOURCE_DEVICE" of="$IMAGE_FILE" bs=4M status=progress

# Generate verification hash
sha256sum "$IMAGE_FILE" > "$HASH_FILE"

# Optional: verify hash against source (requires write blocker removed for this step — not for evidentiary use!)
# sha256sum "$SOURCE_DEVICE" | cmp - "$HASH_FILE" && echo "Hashes match" || echo "Hashes differ"

Responder's checks — real commands: verify image integrity and prepare for analysis. The first validation step, answered in seconds.

# Example session: image validation (defensive)
$ sha256sum /forensic/images/exhibit1.dd
a1b2c3d4e5f6...  /forensic/images/exhibit1.dd
$ cat /forensic/images/exhibit1.dd.sha256
a1b2c3d4e5f6...  /forensic/images/exhibit1.dd
$ echo "Hashes match. Image is ready for analysis."
$ volatility -f /forensic/images/exhibit1.dd --profile=Win10x64_19041 pslist | head -20

Comparative data and specs

The table on the right is this document's data spine: documented outcomes for cases that encounter encrypted devices, with the one sourced figure in the field's public record — Forte's 2009 finding that about 60% of such cases go unprocessed — and the remainder shown by arithmetic difference.

It rewards interpretation, because its two rows represent complementary outcomes of the same challenge. The sourced 60% figure highlights a persistent gap in capabilities: when full-disk encryption prevents access, investigations often stall without viable decryption keys or exploits. The unprocessed majority is the documented state of the field as Forte reported it in 2009; the remaining row is simply what the difference implies, not an independently measured successful-processing rate, and the reader should treat it as the ceiling that tooling, key recovery, and compelled-disclosure law have striven against — while the "Unprocessed" row underscores where continued research into cryptographic weaknesses and legitimate key-management practice matters most.

OutcomeShare of cases
Cases involving encrypted devices that go unprocessedAbout 60% (documented, Forte 2009)
Remainder of such cases, implied by the differenceAbout 40% (arithmetic remainder)

Outcomes where forensic cases encounter encrypted devices — one sourced figure, one remainder by difference.

Access to encrypted devices in digital forensics cases. Forte (2009) documented that about 60% of cases involving encrypted devices go unprocessed because potential evidence cannot be reached; the remainder shown here is implied by the difference.

Unprocessed (documented)60%
Remainder (by difference)40%

Reading — the documented majority of encrypted-device encounters exceed investigative capabilities, and the sourcing discipline matters here: one row is what the field's literature records, the other is arithmetic, not measurement.

Actionable steps for analysts

  1. Imaging preparation

    Verify write blockers are functional and connect via a trusted interface (e.g., USB 3.0 with known serial numbers). Pre-hash the source media using SHA-256 before imaging to establish a baseline. Ensure sufficient storage exists for the image and verify the destination filesystem supports files larger than 4GB if needed.

  2. Memory acquisition discipline

    Prioritize volatile capture before powering down the system. Use dedicated hardware (PCIe DMA) or trusted software tools executed at the highest privilege level. Document the system state (running applications, network connections) through screenshots or logs before acquisition to corroborate memory findings later.

  3. Filesystem/registry pivot points

    Begin analysis with high-value artifacts: recent files, auto-start registry keys, and frequently accessed folders. Correlate timestamp anomalies across filesystem journals and registry hives to identify execution sequences. Employ hash sets to exclude known good files (from NSRL or internal baselines) and focus on unknown or suspicious binaries.

  4. Deleted-data recovery strategy

    Attempt carving on unallocated space and slack files after completing allocated-file analysis. Prioritize file types based on investigation goals (e.g., images for intellectual property theft, documents for fraud). Validate carved files by checking headers/footers and attempting to open them with appropriate viewers to reduce false positives.

  5. Evidence custody and validation

    Maintain an unbroken chain of custody documenting every handler, timestamp, and storage location. Re-hash the image at regular intervals and compare to the original hash to detect alterations. Store images in access-controlled, environmentally stable locations with redundant backups on separate media.

The table pairs each acquisition step with the artifact it creates and the failure it is designed to prevent.

StepArtifact createdFailure prevented
Imaging preparationPre-image SHA-256 and interface recordAn image of the wrong or altered device
Memory acquisitionMemory image plus system-state notesLosing volatile evidence to a power-down
Filesystem and registry pivotTimeline of high-value artifactsMissing the execution sequence
Deleted-data recoveryCarved files validated by header and viewerReporting corrupt or false-positive content
Custody and validationChain-of-custody log and repeated hashesAn image that cannot be shown to be unchanged

Five steps and their records; every row produces something a court or peer can examine independently.

PrepareMemory firstImage diskCarveVerify custody
Volatile evidence first — memory disappears when the machine loses power, while the disk waits; custody records are what make the whole sequence usable later.

Additional context — encryption and the limits of access

The growing prevalence of full-disk encryption poses a fundamental challenge to disk forensics: without the decryption key, the storage media presents as random data, rendering traditional analysis infeasible. Investigators encounter encryption at various levels — BIOS/UEFI passwords, volume-level encryption (BitLocker, FileVault), and container-based solutions (VeraCrypt). Legal avenues like key disclosure statutes or compelled decryption vary by jurisdiction and often face Fifth Amendment challenges in the United States. Technical alternatives include exploiting implementation flaws, recovering keys from memory (if acquired before power loss), or targeting weak passwords through brute force — though strong, properly implemented encryption remains a formidable barrier. The 60% statistic reflects cases where current techniques fail, driving demand for advances in cryptographic analysis and legitimate key management solutions.

Additional context — cloud and volatile storage

Modern infrastructures complicate traditional forensics through elastic storage and ephemeral compute instances. Cloud storage objects may reside in distributed systems with versioning and replication, requiring API-based collection rather than physical disk access. Virtual machine snapshots capture memory and disk state but may omit hypervisor-level artifacts. Containerized applications expose only layered filesystems and runtime parameters, complicating attribution. Investigators adapt by preserving API credentials, securing hypervisor logs, and treating cloud providers as third-party witnesses under legal process. The core principles remain: identify relevant data sources, collect them in a forensically sound manner, and validate integrity through hashing and documentation.

The table sets each modern storage form against the collection problem it creates and the adaptation the page recommends.

SourceCollection problemAdaptation
Cloud storage objectsDistributed, versioned and replicated; no physical disk to imageAPI-based collection with preserved credentials
Virtual machine snapshotsCapture memory and disk but may omit hypervisor artifactsSecure hypervisor logs alongside the snapshot
Containerised applicationsOnly layered filesystems and runtime parameters are exposedPreserve runtime configuration and image layers
Cloud provider recordsHeld by a third partyTreat the provider as a third-party witness under legal process

Modern sources and their adaptations; the unchanged core is to identify, collect soundly, and validate integrity by hashing and documentation.

IdentifyCollectHashDocument
Same principles, new surfaces — elasticity changes where evidence lives, not what makes it defensible: identification, sound collection, integrity, and a record.

Quick reference — the rules at a glance

The page treats disk forensics as a chain in which every link is verifiable. Imaging comes first: a write blocker prevents commands from reaching the device, a tool such as dd produces a bit-for-bit copy, and SHA-256 hashes before and after acquisition show that the image matches the original. Without that hash comparison the image is only a copy, not evidence. Anti-forensics techniques such as hidden partitions, firmware attacks, or interface manipulation are answered with write blockers, hash verification, and authenticated interfaces rather than with trust.

Order of capture follows volatility. Memory is collected before power-down, using hardware such as a PCIe DMA card or a trusted high-privilege tool, and the running state is documented so that later memory findings can be corroborated. Disk analysis then reads filesystem structures and the registry: NTFS, FAT32, ext4, and APFS each need a parser that understands journaling, compression, and encryption, while hives such as SYSTEM, SOFTWARE, and NTUSER.DAT reveal auto-start locations, installed software, and user settings. Timelining ties filesystem changes to registry changes.

Deleted data is recovered by carving raw data for signatures, structures, or statistical patterns, and the result is validated by header and viewer before it is reported. Two limits are stated plainly. Strong encryption without a key leaves random data, and legal routes to compulsion vary by jurisdiction. Cloud and ephemeral systems move evidence behind APIs and third parties, so collection method changes even though identification, sound collection, hashing, and documentation do not.

The first table reduces the page's practices to the rule each imposes and the failure it prevents.

PracticeRuleFailure it prevents
ImagingWrite-block, copy, hash before and afterAn image that cannot be shown to match the source
Memory captureCollect before power-downVolatile evidence lost to shutdown
Filesystem and registryParse with the right tool, then timelineReading structure as if it were content
Deleted-data carvingValidate before reportingCorrupt or false-positive recovery
CustodyRecord every handler and re-hashAn unaccountable gap in the evidence

Five practices and their rules; the third column is the specific failure each rule answers.

The second table turns the limits into questions an investigator should answer in the report.

QuestionWhy the report must answer it
Were source and image hashes identical?It is the proof of fidelity
Was memory captured before shutdown?It sets what volatile evidence exists
Was encryption encountered and how?It explains what could not be examined
Was carved data validated?It separates recovery from invention
Where does cloud evidence now reside?It defines the custodian and legal route

Five questions and their purpose; unanswered limits read as gaps, while stated limits read as method.

AcquireHashAnalyseValidateDocument
Proof at both ends — hashing sits immediately after acquisition and documentation closes the sequence, so the analysis in between can be challenged without the evidence being lost.