Tools:Memory Imaging

From Forensics Wiki
Revision as of 14:39, 13 July 2012 by C Andras Moritz (Talk | contribs)

Jump to: navigation, search

The physical memory of computers can be imaged and analyzed using a variety of tools. Because the procedure for accessing physical memory varies between operating systems, these tools are listed by operating system. Once memory has been imaged, it is subjected to memory analysis to ascertain the state of the system, extract artifacts, and so on.

One of the most vexing problems for memory imaging is verifying that the image has been created correctly. That is, verifying that it reflects the actual contents of memory at the time of its creation. Because the contents of memory are constantly changing on a running system, the process can be repeated but the results will never--to a high degree of probability--be the same. Thus, repeating the acquisition and comparing the results is not a feasible means of validating correct image creation. Memory analysis can reveal whether the image's contents are consistent with the known layout and structure of a given operating system, as well as answering other questions, but it cannot answer the question as to whether the image accurately reflects the system from which it was taken at the time it was taken.


Memory Imaging Techniques

Crash Dumps
When configured to create a full memory dump, Windows operating systems will automatically save an image of physical memory when a bugcheck (aka blue screen or kernel panic) occurs. Andreas Schuster has a blog post describing this technique.
LiveKd Dumps
The Sysinternals tool LiveKd can be used to create an image of physical memory on a live machine in crash dump format. Once livekd is started, use the command ".dump -f [output file]"
Hibernation Files
Windows 98, 2000, XP, 2003, and Vista support a feature called hibernation that saves the machine's state to the disk when the computer is powered off. When the machine is turned on again, the state is restored and the user can return to the exact point where they left off. The machine's state, including a compressed image of physical memory, is written to the disk on the system drive, usually C:, as hiberfil.sys. This file can be parsed and decompressed to obtain the memory image. Once hiberfil.sys has been obtained, Sandman can be used to convert it to a dd image.
Mac OS X very kindly creates a file called /var/vm/sleepimage on any laptop that is suspended. This file is NOT erased when the machine starts up. It is unencrypted even if the user turns on File Vault and enables Secure Virtual Memory. [1].
It is possible for Firewire or IEEE1394 devices to directly access the memory of a computer. Using this capability has been suggested as a method for acquiring memory images for forensic analysis. Unfortunately, the method is not safe enough to be widely used yet. There are some published papers and tools, listed below, but they are not yet forensically sound. These tools do not work with all Firewire controllers and on other can cause system crashes. The technology holds promise for future development, in general should be avoided for now.
At CanSec West 05, Michael Becher, Maximillian Dornseif, and Christian N. Klein discussed an exploit which uses DMA to read arbitrary memory locations of a firewire-enabled system. The paper lists more details. The exploit is run on an iPod running Linux. This can be used to grab screen contents.
This technique has been turned into a tool that you can download from:
The Goldfish tool automates this exploit for investigators needing to analyze the memory of a Mac.
Virtual Machine Imaging
There are numerous popular virtual machines that are in wide use such as xen, qemu or vmware. If the memory image is for a machine running in this kind of virtual environment, there are usually two methods for obtaining a memory image. The common method is to pause/suspend/stop the system and then collect the resulting memory image file, this has the disadvantage of taking the machine offline during the suspend time. Alternatively most of these systems support live dumping of a memory image. Qemu supports the pmemsave function, Xen has the xm dump-core command.

Memory Imaging Tools

x86 Hardware

WindowsSCOPE CaptureGUARD PCIe card (commercial) - desktops, servers
Publicly available, supports all Windows OS; windd and other formats.
CaptureGUARD Gateway performs DRAM acquisition even on locked computers
Inquire at
WindowsSCOPE CaptureGUARD ExpressCard (commercial) - laptop applications
Publicly available, supports all Windows OS; windd and other formats.
CaptureGUARD Gateway performs DRAM acquisition even on locked computers
Inquire at
Tribble PCI Card (research project)
CoPilot by Komoku
Komoku was acquired by Microsoft and the card was not made publicly available.
Forensic RAM Extraction Device (FRED) by BBN
Not publicly available.

Windows Software

There are many Windows memory acquisition tools. Most of them will not work on Windows Vista or 7, as user programs have been denied access to the \Device\Physicalmemory object starting in Windows 2003 Service Pack 1 and Windows Vista. Modern tools acquire physical memory by first installing a device driver, so administrative privileges are needed.

We have edited this list so that it only includes current tools:

WindowsSCOPE Pro and Ultimate, available at
Can capture, analyze, graph in depth physical and virtual memory codes and structures
Proprietary and standard formats (windd), snapshot repository, snapshot comparison
All Windows OSs (Xp, Vista, 7), 32 and 64 bit supported
Phantom Probe USB based fetch
CaptureGUARD PCIe card and ExpressCard for hardware-assisted DRAM acquisition
CaptureGUARD Gateway for hardware-assisted DRAM acquisition of locked computers
launched in 2011
WindowsSCOPE Live
available at and Android market
allows live memory analysis of Windows computers from Android phones and tablets
launched in 2011
winen.exe (Guidance Software - included with Encase 6.11 and higher)
included on Helix 2.0
Mdd (Memory DD) (ManTech)
Can capture and analyze memory. Supports reading dumps (raw/dd format) from other tools.
This utility is used to generate a physical memory dump of Windows machines. It works with both x86 (32-bits) and x64 (64-bits) machines.
The raw memory dump is generated in the current directory, only a confirmation question is prompted before starting.
Perfect to deploy the executable on USB keys, for quick incident responses needs.
Fastdump and Fastdump Pro
Fastdump (free with registration) Can acquire physical memory on Windows 2000 through Windows XP 32 bit but not Windows 2003 or Vista.
Fastdump Pro Can acquire physical memory on Windows 2000 through Windows 2008, all service packs. Additionally, Fastdump Pro supports:
-32 bit and 64 bit architectures
-Acquisitions of greater than 4GB
-Fast acquisitions through the use of larger page sizes (1024KB) but also supports a strict mode that enforces 4KB page sizes.
-Process probing which allows for a more complete memory image of a process of interest.
-Acquisition of the system page file during physical memory acquisition. This allows for a more complete memory analysis.
FTK Imager
FTK Imager
FTK Imager can acquire live memory and paging file on 32bit and 64bit systems.


On older Linux systems, the program dd can be used to read the contents of physical memory from the device file /dev/mem. On recent Linux systems, however, /dev/mem provides access only to a restricted range of addresses, rather than the full physical memory of a system. On other systems it may not be available at all. Throughout the 2.6 series of the Linux kernel, the trend was to reduce direct access to memory via pseudo-device files. See, for example, the message accompanying this patch:
On Red Hat systems (and those running related distros such as Fedora or CentOS), the crash driver can be loaded to create pseudo-device /dev/crash for raw physical memory access (via command "modprobe crash"). This module can also be compiled for other Linux distributions with minor effort (see, for example, When the crash driver is modified, compiled, and loaded on other systems, the resulting memory access device is not safe to image in its entirety. Care must be taken to avoid addresses that are not RAM-backed. On Linux, /proc/iomem exposes the correct address ranges to image, marked with "System RAM".
Second Look: Linux Memory Forensics
This commercial memory forensics product ships with a modified version of the crash driver and a script for safely dumping memory using the original or modified driver on any given Linux system.
fmem is kernel module that creates device /dev/fmem, similar to /dev/mem but without limitations. This device (physical RAM) can be copied using dd or other tool. Works on 2.6 Linux kernels. Under GNU GPL.
Linux Memory Extractor (LiME) is a Loadable Kernel Module (LKM), which allows the acquisition of volatile memory from Linux and Linux-based devices, such as those powered by Android. The tool supports dumping memory either to the file system of the device or over the network.

Mac OS X

Goldfish is a Mac OS X live forensic tool for use only by law enforcement. Its main purpose is to provide an easy to use interface to dump the system RAM of a target machine via a Firewire connection. It then automatically extracts the current user login password and any open AOL Instant Messenger conversation fragments that may be available. Law Enforcement may contact for download information.
Mac Memory Reader
Mac Memory Reader is a simple command-line utility to capture the contents of physical RAM. Results are stored in a Mach-O binary file. Mac Memory Reader is available free of charge. It executes directly on 32- and 64-bit target machines running Mac OS X 10.4 through 10.7 and requires a PowerPC G4 or newer, or any Intel processor.


Qemu allows you to dump the memory of a running image using pmemsave.
e.g. pmemsave 0 0x20000000 /tmp/dumpfile
Xen allows you to live dump the memory of a guest domain using the dump-core command.
You can list the available machines to find the host machine you care about using xm list and see the configuration.
Dumping is a matter of sudo xm dump-core -L /tmp/dump-core-6 6

See Also

External Links