Article 002 · Acquisition

Live vs. Dead Acquisition

You're standing in front of a compromised Linux server. Before you touch anything, you have to make a choice that shapes the entire investigation: do you collect evidence from the live system, or do you pull the plug and image the disk? This article walks through the trade-offs of both.

The core decision

Live acquisition means running commands on the running system to capture volatile data. Dead acquisition means powering it down and imaging the drives in a controlled way. Neither is always right — the correct answer depends on what you're trying to prove and what you can risk losing.

Critical Running any command on a live system changes it. Even ls touches the access time of a directory. Live acquisition is a trade-off: you collect volatile data that otherwise disappears, at the cost of altering some evidence.

The order of volatility

Evidence disappears at very different rates. RFC 3227 lays out the order in which you should collect, from most to least volatile:

  1. Registers and cache (lost instantly)
  2. RAM and swap
  3. Network state (routes, connections, ARP cache)
  4. Running processes and open files
  5. Temporary files on disk (/tmp)
  6. Disk (persists, but increasingly overwritten)
  7. Remote logs and backups (least volatile)

The practical meaning: if you want memory, you must get it while the machine is running. The moment the power is cut, everything above the "temporary files" line is gone forever.

Live acquisition

Choose live collection when:

Risks:

A minimal live-response kit, executed from a mounted read-only USB:

date -u                      # trusted time from your own env, note offset
mount                        # what's mounted, and how
cat /proc/net/tcp            # TCP connections (better than ss here)
arp -a                       # ARP cache
ss -tulpn                    # listening & established sockets
ps auxww                     # process list
lsof                         # open files per process
cat /etc/passwd              # accounts (tamper-prone, but collect)
history                      # shell history of the current shell
Tool discipline Never trust the compromised system's own binaries for critical findings. Either hash them against a trusted database, or use statically-compiled copies of your tools from your evidence kit.

Dead (static) acquisition

Choose dead acquisition when:

The workflow:

  1. Power the system down cleanly if possible; pull the drive with a proper write-protected method.
  2. Connect the drive to a forensic workstation via a write blocker.
  3. Image the drive with dd/dcfldd, hash the original and the image.
  4. Analyze the image; never work on the original.
Never Never boot the suspect drive. Booting mounts it read-write, updates logs, changes timestamps, and destroys the very evidence you came for. Always use a write blocker or a read-only forensic boot.

Choosing: a quick comparison

FactorLiveDead
Memory capturePossibleLost
Active connectionsVisibleGone
Deleted file recoveryPoor (live writes overwrite)Best
Encrypted diskOnly option without keysNeeds keys
Evidence integrityAltered by your actionsClean
Production impactMinimalDowntime
Court defensibilityHarder to defendEasier

Capturing memory

If you decide the investigation needs RAM, do it first, before anything else on the system. Common capture methods on Linux:

# 1. /dev/mem or /dev/kmem - raw, often restricted
dd if=/dev/mem of=ram.mem bs=1M

# 2. LiME (Linux Memory Extractor) - kernel module, recommended
insmod lime-<version>.ko "path=/evidence/ram.lime format=lime"

# 3. fmem - driver exposing /dev/fmem
insmod fmem.ko
dd if=/dev/fmem of=ram.dd bs=1M

# verify it's a sane dump
file ram.lime
sha256sum ram.lime

Analyze the dump with Volatility, which knows how to read LiME format natively and can also handle raw dd dumps given a profile.

Legal & practical checks


← Previous: Introduction to Linux Forensics  ·  Next: Recovering Deleted Files on ext4 →