What is a memory image?
Memory image: sample of the state of the physical memory at a given point in time.
To translate a virtual address to a physical address, perform how many steps?
3 steps:
Compute the Page Directory Entry (PDE)
Compute the Page Table Entry (PTE)
Compute the Physical Address (PA)
In the IA-32 architecture, CR3 contains the physical address of …?
the initial structure used for address translation.
The CR3 register is updated during context switches when a new task is scheduled.
On Linux, shared kernel space is at the top or bottom of the available address space?
top.
No user space layout (Linux) o stack está em cima ou em baixo?
Cima.
The kernel uses the list of active processes to maintain a set of active processes. Is this list exported to userland?
No.
The init_task variable is statically allocated within the kernel, initialized at boot, has a PID of 0, and has a name of swapper. Does it appear in process lists generated through the ps command or /proc?
No.
What is volantility?
Volatility: A memory analysis framework.
Forensic interpretation of memory dumps:
Method #1: Tree / list traversal
Method #2: Fingerprint / pattern search
Memory reconstruction approaches’ pros/cons.
Method #1: Tree / list traversal:
- Can stitch together more related records from kernel perspective
- Can miss unlinked, dead structures (Con)
Method #2: Fingerprint / pattern search:
- Find unlinked, dead structures (warm reboot)
- Can work with imperfect dumps
- Less context without following related structures/objects (Con)
- Susceptible to rubbish (Con)
O que é fileless malware?
Fileless malware é malware que não escreve um binário persistente no disco (ou escreve muito pouco). Em vez disso, ele executa e mantém suas funcionalidades na memória (RAM) usando mecanismos legítimos do sistema — por exemplo, interpretadores de script, carregamento dinâmico de código em processos confiáveis, abuso de ferramentas administrativas (PowerShell, WMI, Python, etc.). O objetivo é evitar a detecção por scanners que vasculham ficheiros em disco.
Traditional methods of digital forensics searching in persistent
storage would find it difficult with assessing this type of malware;
making tools like Volatility all the more important.
Identifying malicious processes.
Usually, look at what processes were running when the RAM dump was captured
- Malware can hide but it must run :) -> Looking at the running processes of a device is always a great way to try and identify any malware that may be running on the device
What does pslist do?
pslist: lists running processes.
pslist: shows the network connections associated with the RAM dump
What does pstree do?
pstree: helps to get an idea of what process spawned another process.
Can also help detect malicious processes masquerading as legitimate Windows processes:
- Masquerading occurs, e.g., by naming the running malware process after legitimate Windows processes
When a RAM dump is captured do network connections at the time the capture was taken will also be stored within the captured memory?
Yes.
What is Symantec?
Symantec runs a monitoring service that keeps a searchable database of malicious URLs
- Let’s visit Symantec Site Review and see if we find information about these IPs.
What are Indicators of compromise (IOCs)?
Serve as forensic evidence of potential intrusions on a host system
or network. These artifacts enable us to detect intrusion attempts or
other malicious activities.
Examples of IOCs?
What is procdump?
procdump: This will extract the executable and all of the associated DLLs.
What are 5 tradeoffs when choosing the acquisition technique?
Two main factors can be used to help make a decision when choosing the acquisition technique.
Software-based: User level tools for acquisition.
Based on user-level tools for memory dumping
- Acquire copy of physical memory (e.g., Data-Dumper)
- Dump the memory contents of a process to a file (e.g., PMDump)
Strengths of this technique:
- Good for incident scenarios
- Capturing forensic image even in situations with little time
Weaknesses of this approach:
- Work on specific operating systems only, E.g., several tools resort to OS-provided device interfaces like /dev/mem that are disabled in many cases for security reasons
- Applications must be loaded into memory before execution
- Depends on functions of the OS, E.g., rootkit may deny access to physical memory or modify the RAM
- May require administrator/root privileges
What is ptrace?
Userland debugging interface that Linux provides:
- The interface is limited for robust memory acquisition, because it can acquire pages only from running processes, which misses all kernel memory, freed pages, and other data;
- The only time you should use ptrace as an acquisition method
is when you are interested in the code and data of only one
process, such as related to a piece of malware.
Software-based: Kernel level drivers for acquisition.
Leverage a kernel driver / module to access physical memory without restrictions, aceder à RAM de forma controlada.
e.g. -> fmem, Linux Memory Extractor (LiME).