TR1.5 Memory Acquisition: Tools, Techniques, and Verification
Figure TR1.5 — Memory acquisition tool selection. Each environment has a primary tool (lowest friction, fewest dependencies) and alternatives. Cloud instances require guest-level tools (AVML/WinPMEM) because hypervisor-level capture is not available on public cloud.
Windows memory acquisition with WinPMEM
Six-step method — Windows memory capture:
What to look for: A complete copy of the system’s physical RAM containing all running processes, their memory contents, loaded DLLs, kernel data structures, and network state.
Where to find it: Physical RAM, accessible via a kernel driver that WinPMEM loads temporarily.
How to extract it:
| |
How to interpret and verify the output:
| |
Critical: write the dump to EXTERNAL media (USB, network share), NOT the target system’s disk. Writing a 16 GB dump to the target’s C: drive overwrites 16 GB of unallocated disk space — potentially destroying deleted files that the investigation team could have recovered. The USB drive should be formatted with NTFS (FAT32 has a 4 GB file size limit — insufficient for memory dumps).
What WinPMEM captures that volatile triage commands cannot:
The ps and tasklist commands show the CURRENT process list at the moment they execute. A memory dump captures the process list PLUS: the full memory contents of each process (code, data, heap), the process environment block (PEB) containing loaded DLLs and environment variables, the kernel’s EPROCESS structure (including hidden processes that rootkits remove from the active process list), VAD (Virtual Address Descriptor) trees showing all memory regions (including injected code), and open handles (files, registry keys, network sockets, mutexes).
Volatility3 plugins extract this data from the dump: windows.pslist (process list), windows.pstree (parent-child relationships), windows.netscan (network connections with owning process), windows.malfind (injected code detection), windows.handles (open handles per process), windows.cmdline (full command lines), windows.dlllist (loaded DLLs per process), windows.hashdump (cached NTLM hashes from the SAM), and windows.lsadump (LSA secrets including service account passwords).
Linux memory acquisition with AVML and LiME
AVML (primary tool). Single static binary, no kernel module, no compilation required. Reads from /dev/crash or /proc/kcore.
| |
LiME (fallback — higher quality, more complex). Kernel module that reads physical memory directly. Requires a pre-compiled .ko file matching the EXACT running kernel version.
| |
AVML vs LiME decision:
Use AVML when: rapid acquisition is needed (no preparation required), the kernel is 4.x+ (AVML requires /dev/crash or /proc/kcore), and you do not have a pre-compiled LiME module for the target kernel.
Use LiME when: AVML fails (restricted /dev/crash on hardened systems), you need the highest dump quality (LiME reads physical memory directly through the kernel, potentially capturing more consistent data), or the target is an older kernel where AVML’s /dev/crash reading is unreliable.
Pre-compiling LiME modules for your fleet: Maintain a directory of pre-compiled LiME .ko files for every kernel version running in your environment. After every kernel update: compile a new LiME module on a clean system with the matching kernel headers and add it to the triage USB. This 5-minute preparation step eliminates the “I don’t have a LiME module for this kernel” problem during incidents.
| |
ISF generation for Volatility3 — the critical dependency
Volatility3 cannot parse a Linux memory dump without an ISF (Intermediate Symbol Format) file matching the target kernel. The ISF maps kernel data structure offsets to named fields — without it, the raw memory is uninterpretable bytes.
Three ISF generation methods:
| |
Collect these during triage to enable ISF generation later:
| |
Cloud and virtual machine memory acquisition
VMware ESXi / vSphere: Suspend the VM or create a snapshot. The snapshot includes a .vmem file containing the VM’s physical memory. Copy the .vmem file for Volatility3 analysis. Do NOT resume the VM before copying — resuming overwrites the suspended memory state.
Hyper-V: Create a checkpoint (Export-VM produces a .bin file containing memory). Or use WinPMEM from within the guest OS.
AWS EC2 / Azure VM / GCP Compute: Cloud providers do NOT offer hypervisor-level memory capture for customer VMs. Memory acquisition requires guest-level tools: deploy AVML (Linux) or WinPMEM (Windows) inside the instance. For EC2: use SSM Run Command to execute AVML remotely without SSH. For Azure: use Run Command via the Azure portal or CLI.
| |
Investigation Finding — IF-2026-TR1-MEM-001
Artifact: Memory acquisition procedure reference
Source: Operational standard — not incident-specific.
Findings:
Memory acquisition toolkit for the NE environment requires:
Windows: WinPMEM v4.0 on triage USB. ISF auto-detected by Volatility3 for Windows 10/11 and Server 2016+.
Linux: AVML v0.14.0 (primary) + pre-compiled LiME modules for 3 kernel versions currently deployed (5.15.0-88, 5.15.0-91, 6.1.0-18). ISFs pre-generated via btf2json for all 3 kernels.
Cloud: WinPMEM/AVML deployed via SSM/Run Command. No hypervisor-level capture available.
Proves: The NE triage toolkit supports memory acquisition across all 3 environments without preparation delays. Pre-compiled LiME modules and pre-generated ISFs eliminate the “I can’t analyse the dump because I don’t have the profile” problem.
Does not prove: That the toolkit is current — kernel updates may introduce new versions that require new LiME modules and ISFs. The triage toolkit must be updated after every kernel patch cycle.
Next step: Add toolkit maintenance to the monthly SOC operations checklist: after every kernel update, compile new LiME module, generate new ISF, add both to the triage USB.
Reference: Microsoft AVML (github.com/microsoft/avml), 504ensics LiME (github.com/504ensicsLabs/LiME), Volatility Foundation (github.com/volatilityfoundation/volatility3).
Try it: test memory acquisition on a non-production system
- Windows: Download WinPMEM. Run as Administrator. Capture a test dump to a USB drive. Verify the size matches physical RAM. Record the SHA256 hash. Delete the test dump.
- Linux: Download AVML. Run as root. Capture a test dump. Verify size. Record hash. Check whether /sys/kernel/btf/vmlinux exists (determines ISF generation method).
- For both: time the acquisition — know how long it takes for your typical system RAM size so you can plan triage timing during real incidents.
The myth: Memory acquisition requires expensive forensic hardware (JTAG interfaces, direct memory access devices, PCI-based acquisition cards) and is beyond the capability of a SOC analyst during triage.
The reality: Software-based memory acquisition using WinPMEM (Windows) and AVML (Linux) requires: a single executable file on a USB drive, administrator/root access to the target system, and external storage for the dump. No specialised hardware. No forensic workstation. No physical access to the system’s motherboard. The tools are free and open-source. A SOC analyst who has practised the acquisition procedure once can execute it in under 5 minutes during a real incident. Hardware-based acquisition (JTAG, DMA) is reserved for forensic scenarios where the OS is untrusted (rootkit contamination at the kernel level) or the system cannot be accessed through the OS (locked screen, encrypted disk, powered-off device). For triage — where the system is running and accessible — software-based acquisition is sufficient and standard.
Troubleshooting
“WinPMEM fails with ‘Cannot load driver’.” Cause: Secure Boot or Driver Signature Enforcement is blocking the unsigned WinPMEM driver. Solutions: (1) Use the signed version of WinPMEM if available. (2) Temporarily disable Driver Signature Enforcement: bcdedit /set nointegritychecks on (requires reboot — not ideal during triage). (3) Use DumpIt or Magnet RAM Capture as alternatives (both use signed drivers). (4) If on a VM: use hypervisor-level capture instead.
“AVML fails with ‘Permission denied’ on /dev/crash.” Some hardened Linux configurations restrict /dev/crash. Try: avml --source /proc/kcore /IR/memory.lime. If both fail: use LiME with a pre-compiled kernel module. If LiME is also unavailable: document “Memory acquisition not possible on this system” and proceed with volatile state capture (ps, ss, w) as the best available alternative.
“The memory dump file is much smaller than physical RAM.” Common causes: (1) Insufficient disk space on the output media — check df -h. (2) The dump was written to FAT32 media (4 GB file size limit) — use NTFS or ext4. (3) AVML encountered memory regions it could not read and skipped them. A dump within 90% of physical RAM is acceptable for analysis; a dump below 50% may have significant gaps requiring re-acquisition with an alternative tool.
You're reading the free modules of this course
The full course continues with advanced topics, production detection rules, worked investigation scenarios, and deployable artifacts. Premium subscribers get access to all courses.