Hard drives and SSDs: how they work
How disks work from a forensic point of view: magnetic platters and flash memory, controllers, TRIM and internal clean-up, interfaces, HPA and DCO areas, SMART data, software and hardware encryption, Macs with Apple chips.
| Aspect | Hard drive | SSD |
|---|---|---|
| Storage | Magnetic platters read by heads | Flash memory cells managed by a controller |
| Deleted data | Remains until overwritten | The disk may wipe it on its own after TRIM |
| Writes | The system decides where to write | The controller moves data to spread wear |
| Autonomous activity | None without commands | Internal clean-up even without system writes |
| Interfaces | SATA, SAS and, in older models, IDE | SATA, NVMe on M.2 or PCIe, sometimes soldered to the motherboard |
| Failures | Mechanical: heads, motor, bad sectors | Electronic: controller, firmware, worn-out cells |
| Laboratory recovery | Often possible even with damaged disks | Difficult: data are scattered and often encrypted by the controller |
TRIM and internal clean-up
When the operating system deletes a file on an SSD it sends the TRIM command, called Deallocate on NVMe drives: the disk notes that those blocks are no longer needed and, during internal clean-up, wipes them so they can be rewritten. Many SSDs return zeros for freed blocks immediately after the command, even before physically erasing them. That is why a file deleted on a modern SSD is, in most cases, unrecoverable.
Hidden areas and disk data
Disk standards allow part of the capacity to be reserved and made invisible to the operating system: the Host Protected Area (HPA) and the Device Configuration Overlay (DCO). They exist for legitimate purposes, such as manufacturers’ recovery partitions, but can hide data. The firmware also records SMART data: power-on hours, number of power cycles, reallocated sectors, amount of data written.
Hard drives and SSDs: the procedure
The procedure for acquiring hard drives and SSDs: assess the computer’s state, document, decide whether to shut down, remove the disk or boot a forensic system, write blocker, HPA, DCO and SMART checks, sector-by-sector copy, verification, encryption, damaged disks.
The pages of this topic
Back to the overviewHard drives and SSDs: tools
The tools for acquiring and analysing hard drives and SSDs: write blockers for SATA, SAS, NVMe and USB, copying programs such as FTK Imager, Guymager, dc3dd and ewfacquire, bootable forensic systems, hdparm and smartctl, ddrescue and laboratory equipment, analysis programs, unlocking BitLocker and FileVault.
Hard drives and SSDs: mistakes to avoid
The most common mistakes with hard drives and SSDs: connecting them without a write blocker, powering them up out of curiosity, shutting down an open encrypted volume, ignoring HPA and DCO, re-copying an SSD, assuming there is no encryption, persisting with a failing disk, not recording the serial number.
Hard drives and SSDs: value in court
The rules on acquiring disks: preserving original data after Italian Law 48/2008, compliant and unmodifiable copies, repeatable and non-repeatable examinations, returning the disk after copying, passwords and keys, keys held by providers, civil proceedings and court-ordered description.
Hard drives and SSDs: a case
A guided case: the company laptop of a departing employee, with an SSD and BitLocker, is acquired using the company’s recovery key; deleted files cannot be recovered, but usage traces show the projects opened from a USB stick.
Hard drives and SSDs: checklist
The checklist for acquiring hard drives and SSDs: before touching the disk, during the copy, after the copy.
Hard drives and SSDs: frequently asked questions
Short answers to the most common questions about the forensic examination of hard drives and SSDs.