Skip to content

Evidence Preservation During Containment

Containment is the phase where the pressure to stop an attack conflicts most directly with the need to preserve evidence. This topic covers write-blocker use, forensic image acquisition priority, chain-of-custody documentation, and the legal standards that govern evidence handling in major jurisdictions.

Last updated:

Share

Evidence preservation during containment is the discipline of ensuring that digital artefacts remain forensically sound while the immediate threat is being isolated. When an incident is active, two imperatives compete: stopping the attack quickly and collecting the evidence needed for prosecution, regulatory compliance, or post-incident learning. Handling this tension requires a defined acquisition sequence, write-blocker use, cryptographic verification of copies, and contemporaneous documentation that can withstand scrutiny in legal or regulatory proceedings. Failure to follow these disciplines does not simply weaken a court case; it can make evidence inadmissible, expose the organisation to civil liability, or prevent attribution entirely.

The core problem is that digital evidence is fragile. Running processes, network connections, memory contents, and file timestamps change or disappear the moment power is removed or a containment action is taken. A responder who isolates a compromised host from the network without first capturing volatile data has permanently destroyed evidence that cannot be reconstructed. At the same time, a responder who delays containment to collect evidence while an attacker continues to exfiltrate data has made a different kind of error. Both errors are avoidable with a written acquisition plan that defines what to collect, in what order, and when containment can proceed.

Legal frameworks in every major jurisdiction impose requirements on how digital evidence must be handled to be admissible. In the United States, the Federal Rules of Evidence and the Computer Fraud and Abuse Act shape what investigators must demonstrate about their methods. In the United Kingdom, the ACPO Good Practice Guide for Digital Evidence (now maintained by the Forensic Science Regulator) sets the standard. The European Union's eEvidence regulation coordinates cross-border evidence access. India's Bharatiya Sakshya Adhiniyam 2023, which replaced the Indian Evidence Act 1872, now governs electronic records, and its Section 63 conditions on electronic evidence certification apply to incident response artefacts. Responders working across jurisdictions must know which rules apply and plan their collection accordingly.

By the end of this topic you will be able to:

  • Explain the order of volatility and apply it to sequence evidence collection before and during containment.
  • Describe how hardware and software write-blockers work and identify when each is appropriate.
  • Outline the steps required to create a forensically sound image and verify its integrity with a cryptographic hash.
  • Produce chain-of-custody documentation that meets the requirements of at least two major legal frameworks.
  • Identify the legal admissibility conditions for digital evidence under US, UK, EU, and Indian law.
Key terms
Order of volatility
The sequence in which digital evidence should be collected, ranked from most to least transient. Defined in RFC 3227. CPU registers and cache are most volatile; optical media and printed logs are least volatile. Responders collect in this order to avoid losing evidence that disappears when power is removed or processes terminate.
Write-blocker
A hardware or software device that intercepts write commands to a storage medium and prevents them from executing, while allowing read commands to pass through normally. Used during forensic imaging to ensure the original evidence is not modified by the act of copying it.
Forensic image
A bit-for-bit copy of a storage medium, including all sectors, slack space, and deleted data. Produced using verified imaging tools and validated against the source using a cryptographic hash. The image is the working copy; the original is preserved untouched.
Chain of custody
The documented, unbroken record of every person who collected, received, transferred, examined, or stored a piece of evidence. Required for evidence to be admissible in legal proceedings. Any gap in the chain creates an opportunity to challenge the authenticity of the evidence.
Cryptographic hash (MD5/SHA-256)
A fixed-length digest computed from the contents of a file or disk image. Used to verify that a forensic copy is identical to the source: if both hashes match, the copy has not been altered. SHA-256 is the current standard; MD5 is still reported for legacy compatibility but should not be used alone.
Legal hold
A formal directive, typically from legal counsel, to suspend normal data destruction or overwrite policies for evidence relevant to anticipated litigation or investigation. Failing to issue or enforce a legal hold when litigation is foreseeable can result in spoliation findings and sanctions.

Order of volatility and the acquisition sequence

RFC 3227, published by the IETF in 2002, formalised the concept of an order of volatility for digital evidence. The principle is simple: collect the most transient data first, because it will be lost before more stable data is processed. What matters in practice is applying this sequence in a containment scenario where there is time pressure and where some collection steps must happen before any containment action alters the system state.

PriorityData typeApproximate retentionCollection method
1CPU registers, cacheMillisecondsMemory acquisition tool (live system)
2Running processes, network connectionsUntil process terminatesps, netstat, or EDR snapshot
3RAM contentsUntil power removedMemory acquisition: WinPmem, LiME, FTK Imager
4Swap file / hibernation fileUntil overwrittenLogical copy or full-disk image
5Persistent storage (HDD/SSD)Long-termForensic image via write-blocker
6Log files on remote systemsSubject to retention policyExport via SIEM or syslog pull
7Archived or backed-up dataPer retention scheduleRequest from backup system

The practical decision point is when to cut network access. Isolating a host from the network is usually the first containment action, but it terminates active connections and may end attacker activity that was still producing observable evidence. A brief capture window, typically using a packet capture tool already running or one deployed rapidly from a forensic toolkit, can record the last minutes of network activity before isolation. The decision to delay isolation by even a few minutes must be made by the incident commander, documented with a timestamp and the reason, and coordinated with the legal team if exfiltration is ongoing.

Write-blockers: hardware and software

A write-blocker sits between the source storage device and the forensic workstation. When the operating system or imaging tool sends a read command, the write-blocker passes it through. When a write command is issued, whether intentionally or as a side effect of the operating system mounting the volume, the write-blocker intercepts and discards it. The source medium is never modified.

Hardware write-blockers are physical devices that connect between the drive and the workstation, typically via a bridge interface such as USB, SATA, or SAS. Common examples include the Tableau series (now part of Opentext Forensics) and the WiebeTech UltraDock. Hardware write-blockers are preferred in legal proceedings because their operation is independent of the host operating system: a software misconfiguration or driver issue on the forensic workstation cannot bypass them. Their use is well-established in US federal courts, UK Crown Court proceedings, and comparable judicial systems in EU member states.

Software write-blockers implement the same protection through kernel-level drivers or registry settings. On Windows, the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies\WriteProtect registry value can be set to 1 to block writes to removable storage. On Linux, the 'blockdev --setro' command marks a device read-only. Software write-blockers are faster to deploy and cheaper, but they depend on the operating system layer and can be bypassed by a privilege escalation or a kernel vulnerability. They are acceptable for internal investigations but scrutinised more closely in adversarial legal proceedings.

Forensic image acquisition

A forensic image is a bit-for-bit copy of an entire storage medium, not just the files visible to the operating system. It includes allocated space, unallocated space, slack space, and any sectors the file system considers deleted. This completeness is essential because deleted files, partial file fragments, and artefacts written to slack space are frequently relevant evidence that a file-level copy would miss.

The standard imaging tools in professional practice are dcfldd and dc3dd on Linux (command-line, suitable for scripted pipelines), FTK Imager (Windows GUI, widely used in law enforcement), and EnCase Forensic. Each tool produces a forensic image in one of the common container formats: raw (dd), EnCase Evidence File (E01), or Advanced Forensic Format (AFF4). E01 is most widely accepted in legal proceedings across the US, UK, Australia, and much of Europe because its internal segment headers include checksums and the format is well-documented. AFF4 is the modern open-standard alternative and is increasingly accepted.

The acquisition process follows a fixed sequence. First, document the physical state of the device: serial number, model, visible damage, and the interfaces present. Second, connect the device through the write-blocker. Third, compute a hash of the source before imaging begins. Fourth, run the imaging tool and record its command or settings. Fifth, compute a hash of the resulting image. The source hash and image hash must match; if they do not, the imaging process introduced an error or the tool is unreliable. Both hashes are recorded in the case notes and signed by the investigator. This is the baseline verification that the image is forensically sound.

Chain-of-custody documentation

Chain of custody is the paper trail that answers one question: at every point between initial collection and presentation in court, who had this evidence, and what did they do with it? The chain must be unbroken. Every transfer of physical or logical custody requires a dated entry recording the transferring party, the receiving party, the reason for transfer, and the condition of the evidence at transfer. Where a physical item is involved, a tamper-evident seal is applied after acquisition and its serial number is recorded; any subsequent opening of the seal is documented.

A chain-of-custody form typically records: unique evidence identifier (case number plus item number), description of the item, date and time of collection, location of collection, name and role of the collecting officer, hash values at acquisition, storage location, and the complete transfer log. In high-stakes proceedings the form is signed in ink; in many organisations a digital evidence management system such as Cellebrite Commander, UFED, or a custom case management platform maintains the log electronically with audit trails.

Legal requirements vary by jurisdiction. In the US, Federal Rule of Evidence 901 requires authentication, which for digital evidence means demonstrating the item is what it is claimed to be through testimony, hash comparison, or system logs. In the UK, the Forensic Science Regulator's Codes of Practice and Conduct require compliance with ISO/IEC 17025 accreditation standards for forensic laboratories. In India, the Bharatiya Sakshya Adhiniyam 2023 requires a certificate from a responsible official when electronic records are produced as evidence, specifying the device, the method of production, and the person who produced it. The EU's Directive 2014/41/EU on the European Investigation Order requires that evidence gathered under the directive follows the procedural law of the executing state, which means chain-of-custody requirements differ across member states.

Containment decisions and their evidence impact

Every containment action has an evidence consequence. Isolating a host from the network terminates active connections and may stop attacker activity that was being observed. Killing a malicious process removes it from the process list and may overwrite memory pages that contained its code. Changing a compromised account's password invalidates active sessions and destroys session tokens that might have identified the attacker's toolchain. These trade-offs cannot be avoided, but they must be recorded.

The practical approach is to define containment tiers in the incident response plan before an incident occurs. A low-severity tier might allow network isolation without mandatory volatile capture; a high-severity tier involving suspected ransomware or a nation-state actor requires volatile data capture as a precondition to any containment action except in defined emergency circumstances. The NIST SP 800-61 revision 2 framework and the SANS PICERL model both anticipate that containment decisions will be made with evidence considerations in mind, but neither mandates a specific sequence because that must be adapted to the organisation's risk tolerance and legal obligations.

Documentation during containment must be contemporaneous. Contemporaneous means recorded at the time of the action, not reconstructed from memory afterwards. Tools such as Notepad with timestamps, a running terminal session logged to a file, or a dictated voice memo with timestamp are all acceptable. The investigator records: the action taken, the exact time, the person who authorised it, the reason it was taken at that point rather than earlier or later, and what was observed before and after. This record is what allows a court or regulator to reconstruct the decision-making process weeks or months later.

Check your understanding
Question 1 of 4· 0 answered

A responder arrives at a running Windows workstation suspected of compromise. The workstation is actively communicating with an external IP address. According to the order of volatility, what should be captured first?

Key Takeaways

  • The order of volatility (RFC 3227) dictates collection sequence: CPU cache and RAM before disk, active connections before log files, on-system data before backups. Any containment action that destroys volatile data must be weighed against the value of that data and the cost of delay.
  • Hardware write-blockers are the preferred tool for protecting source media during forensic imaging because they operate at the hardware interface and are not vulnerable to operating-system-level bypasses. Software write-blockers are acceptable for internal investigations but face greater scrutiny in court.
  • A forensic image is validated by computing a cryptographic hash of the source before imaging and comparing it to the hash of the image after completion. A mismatch means the image is not forensically sound and cannot be used as an authentic copy.
  • Chain-of-custody documentation must be contemporaneous, complete, and signed at every transfer. Gaps in the chain allow opposing counsel to challenge the authenticity of the evidence and may lead to exclusion.
  • Legal admissibility requirements vary by jurisdiction: the US requires authentication and reliable method, the UK follows ACPO principles and FSR accreditation standards, India's Bharatiya Sakshya Adhiniyam 2023 requires a responsible official's certificate, and EU member states apply their own procedural law with the eEvidence regulation governing cross-border requests. Evidence preservation disciplines designed for criminal proceedings also satisfy regulatory disclosure obligations under data protection law.
What is a write-blocker and why is it required during forensic imaging?
A write-blocker is a hardware or software device that allows read access to a storage medium while preventing any write operations from reaching it. Without a write-blocker, connecting a suspect drive to an investigator's system can modify timestamps, swap-file entries, and other artefacts, making the image legally suspect. Hardware write-blockers are preferred in legal proceedings because they operate at the interface layer independently of the operating system.
What is acquisition priority order when time is limited during containment?
Volatile data disappears when power is removed, so it must be captured first. The standard priority order is: CPU registers and cache, running processes and network connections, RAM contents, swap or hibernation files, then persistent storage. This sequence reflects the descending order of volatility and ensures that the most transient evidence is captured before containment actions that might terminate processes or cut network access.
What does chain of custody mean in digital forensics?
Chain of custody is the documented record of who collected, handled, transferred, and stored each piece of evidence from the moment of acquisition through legal proceedings. Every transfer of custody requires a signature and timestamp. Gaps or inconsistencies in the chain can allow defence counsel to argue the evidence was tampered with, which can lead to exclusion. The chain must be unbroken from seizure to court.
How do legal systems in different countries treat digital evidence admissibility?
Most jurisdictions require that digital evidence be authentic, that collection followed a reliable and documented method, and that chain of custody is unbroken. In the US, the Federal Rules of Evidence govern admissibility in federal courts; in the UK, ACPO Good Practice Guide principles apply; in the EU, the eEvidence regulation and national procedural codes apply. India's Bharatiya Sakshya Adhiniyam 2023 replaced the Indian Evidence Act and now governs electronic evidence admissibility.
Can containment actions be taken before forensic imaging is complete?
Yes, but the sequence must be documented and justified. If a system is actively exfiltrating data or attacking other hosts, containment cannot wait. In that case, volatile data should be captured as quickly as possible, the containment action taken and logged with a precise timestamp and the reason for the decision, and a full forensic image acquired from the isolated system immediately after containment. The key is that every action and its justification is recorded in real time.

Test yourself on Incident Response and Management with free, timed mocks.

Practice Incident Response and Management questions

Found this useful? Pass it along.

Share

Spotted an error in this page? Report a correction or read our editorial standards.

Your journey to becoming a forensic professional starts here.

Practice with mock tests, learn from structured notes, and get your questions answered by a global forensic community, all in one place.