Program Execution Artifacts Investigation Guide

baComplete DFIR Workflow & Cheatsheet


πŸ“š Table of Contents


🎯 Artifact Priority Matrix

Quick Decision Guide: Which Artifact to Check First?

Investigation Goal
Primary Artifacts
Secondary Artifacts
Timeframe

Prove Execution

Prefetch, BAM/DAM

Amcache, SRUM

Minutes

Execution Timeline

Prefetch (last 8 times), BAM/DAM

ShimCache, Timeline

Minutes

User Activity

UserAssist, Jump Lists

Timeline, MRU

15-30 min

Malware Presence

Prefetch, ShimCache, Amcache

BAM/DAM

15-30 min

File Access History

Jump Lists, MRU

Timeline, SRUM

30-45 min

Network Activity

SRUM

Timeline

30 min

Deleted Files

$J, $LogFile

MFT, ShimCache

45-60 min

PowerShell Activity

ConsoleHost_history.txt

Event Logs

15 min

Hidden Data

ADS

MFT

30 min


πŸ” Investigation Workflow

Phase 1: Quick Triage (First 15 Minutes)

Step 1: Determine Investigation Scope

Step 2: Collect Core Artifacts (Live System)

Step 3: Quick Wins - Check These First


Phase 2: Detailed Analysis (30-60 Minutes)

Step 1: Execution Timeline Construction

Step 2: User Activity Analysis

Step 3: Persistence & IOC Extraction


πŸ’Ύ Prefetch Analysis

Overview

  • Purpose: Evidence of program execution with timestamps

  • Location: C:\Windows\Prefetch

  • Format: (exename)-(hash).pf

  • Retention: Up to 1,024 files (128 on Server 2016+)

  • Enabled: Workstations by default, NOT on servers

Key Information Available

Data Point
Description
Forensic Value

Execution Count

Total times executed

Distinguish single vs. repeated execution

Last 8 Run Times

Win10/11 store last 8 timestamps

Timeline of activity

File Path

Original execution location

Identify unusual paths

Files Referenced

DLLs, resources loaded

Understand program behavior

Volumes

Drives accessed

Removable media usage

Creation Time

First execution time (-10 sec)

Initial compromise time

Modification Time

Last execution time (-10 sec)

Most recent activity

Registry Configuration Check

Check if Prefetch is Enabled:

Collection & Analysis

Using PECmd (Prefetch Explorer Command Line):

Using WinPrefetchView:

Analysis Tips

πŸ”΄ Red Flags to Look For:

  1. Multiple Prefetch Files for Same Executable

    • Different hash = different path or command line

    • Indicates executable run from non-standard location

  2. Executables from Suspicious Paths

    • C:\Users\*\Downloads\

    • C:\Users\*\AppData\Local\Temp\

    • C:\Users\Public\

    • C:\$Recycle.Bin\

    • C:\ProgramData\

  3. Known Malware Names

  4. Hosting Applications with Multiple Hashes

  5. Low Run Count with Recent Execution

    • Run count = 1 or 2

    • Recent modification time

    • Possibly newly introduced malware

Prefetch Timeline Analysis:

Pro Tips:

⚠️ CRITICAL: Running forensic tools creates Prefetch files!

  • Prioritize Prefetch collection FIRST

  • Oldest files deleted when limit reached (1,024)

  • Use forensic imaging to preserve evidence

βœ… Win10/11 Compression: Files are compressed - use PECmd to decompress automatically

βœ… Execution != Success: Prefetch created even if program crashes/fails

βœ… Network Execution: Programs run from network shares create Prefetch on local system


⚑ BAM/DAM Analysis

Overview

  • BAM: Background Activity Moderator

  • DAM: Desktop Activity Moderator

  • Purpose: Control background app activity

  • Available: Windows 10 1709+ / Server 2016+

  • Retention: ~7 days

Key Information Available

Data Point
Description

Full Path

Complete path to executable

Last Execution Time

Most recent execution timestamp

User SID

Which user executed the program

Location

Collection & Analysis

Manual Registry Query:

PowerShell Parsing:

Using RegistryExplorer:

Using BamParser.py:

Analysis Tips

Investigation Workflow:

Red Flags:

Limitations:

⚠️ Shows LAST execution only (not historical) ⚠️ ~7 day retention ⚠️ Doesn't prove execution success ⚠️ Can be cleared on reboot (not persistent)


πŸ“‹ ShimCache Analysis

Overview

  • Official Name: Application Compatibility Cache

  • Purpose: Track compatibility settings for programs

  • Key Feature: Tracks executables even if NOT executed

  • Location: SYSTEM registry hive

  • Retention: 1,024 entries (Win7+)

CRITICAL Understanding

Key Information Available

Data Point
Description
Forensic Value

Full Path

Complete path to executable

Identify malware location

File Size

Size of executable

Cross-reference with known malware

Last Modified Time

File's last modification timestamp

Timeline analysis

Existence

Proof file was present

Evidence even if deleted

Location

Collection & Analysis

Using AppCompatCacheParser:

Manual Registry Export:

Analysis Tips

Understanding the Output:

Investigation Workflow:

  1. Sort by CacheEntryPosition (most recent = position 0)

    • Recent activity appears first

    • Useful for timeline

  2. Search for Suspicious Patterns:

  3. Cross-Reference with Prefetch:

Red Flags:

Timeline Analysis:

Pro Tips:

βœ… Deleted File Recovery: ShimCache may be only evidence of deleted malware

βœ… Pre-Execution Evidence: Files scanned by AV/security tools appear in ShimCache

βœ… Network Drive Execution: UNC paths captured if executed

⚠️ False Positives: Installers, Windows Updates create many entries


πŸ—‚οΈ Amcache Analysis

Overview

  • Location: C:\Windows\AppCompat\Programs\Amcache.hve

  • Purpose: Track installed applications and executed programs

  • Key Feature: Contains SHA1 hashes of executables!

  • Retention: Long-term (not time-limited)

Key Information Available

Data Point
Description
Forensic Value

Full Path

Complete path to executable

Malware location

SHA1 Hash

File hash

Malware identification

File Size

Size of file

Cross-reference

Compilation Time

PE header timestamp

Build date

Publisher

Code signing certificate

Legitimacy check

File Version

Version info

Specific variant

Language

Program language

Target analysis

File Modified Time

Last modification

Timeline

CRITICAL Understanding

Collection & Analysis

Collection (Live System):

Collection (FTK Imager):

Using AmcacheParser:

Using Registry Explorer:

Analysis Tips

Key Tables in Amcache:

Investigation Workflow:

  1. Extract SHA1 Hashes:

  2. Check Hashes Against Threat Intelligence:

  3. Identify Suspicious Paths:

  4. Check Unsigned/Unknown Publishers:

  5. Analyze Compilation Times:

Red Flags:

Cross-Reference Strategy:

Pro Tips:

βœ… Hash Database: Build whitelist of known-good Microsoft hashes

βœ… Driver Analysis: InventoryDriverBinary tracks drivers (rootkit detection)

βœ… Portable Apps: External USB executables tracked

⚠️ Compilation Time: Can be forged by attacker


πŸ”— Jump Lists Analysis

Overview

  • Purpose: Track recently/frequently accessed files per application

  • Location: %USERPROFILE%\AppData\Roaming\Microsoft\Windows\Recent\

  • Types:

    • AutomaticDestinations (automatic)

    • CustomDestinations (pinned to taskbar)

  • Retention: ~2,000 items per application

Key Information Available

Data Point
Description
Forensic Value

Target Path

File accessed

Document analysis

Timestamps

Access times

Timeline

File Size

Size of target

Verification

Volume Info

Local/Network/USB

Data exfil detection

Network Path

UNC paths

Lateral movement

MRU Order

Access frequency

User behavior

Location Details

Common Application IDs

AppID
Application

f01b4d95cf55d32a

Microsoft Word

23646679aaccfae0

Microsoft Excel

1b72d5ec7c8ef7f6

Microsoft PowerPoint

5d696d521de238c3

Notepad

9b9cdc69c1c24e2b

File Explorer

fb3b0dbfee58fac8

Remote Desktop

7cfdf86b2e3d65ef

Paint

1ac14e77410f4e4b

Chrome

bc3e45ec13a6059e

Edge

Full List: https://dfir.to/EZJumpList

Collection & Analysis

Collection:

Using JLECmd (JumpList Explorer Command Line):

Using JumpListExplorer (GUI):

Analysis Tips

Investigation Workflows:

1. Recent Document Access:

2. Network Share Access (Lateral Movement):

3. External Drive Usage:

4. Sensitive File Access:

5. RDP Connection History:

Red Flags:

Investigation Scenarios:

Scenario 1: Data Exfiltration

Scenario 2: Lateral Movement

Scenario 3: Document Activity

Pro Tips:

βœ… Persistence: Jump Lists survive file deletion (evidence of deleted files)

βœ… MRU Order: Most recently used = position 0

βœ… Link Files: Each entry is essentially a .lnk file with rich metadata

⚠️ Privacy Mode: Private browsing doesn't create jump list entries


πŸ–±οΈ UserAssist Analysis

Overview

  • Purpose: Track GUI-based program launches

  • Location: NTUSER.DAT registry hive per user

  • Encoding: ROT13 (rotate 13 characters)

  • Retention: Persistent (doesn't age out)

Key Information Available

Data Point
Description
Forensic Value

Program Path

Full path to executable

Malware location

Last Run Time

Most recent execution

Timeline

Run Count

Number of times executed

Frequency analysis

Focus Time

Time application had focus

Usage duration

Focus Count

Times app received focus

User interaction

Location

Collection & Analysis

Manual Registry Query (requires decoding):

Using Registry Explorer (Recommended):

Using RegRipper:

PowerShell Parsing with ROT13 Decode:

Analysis Tips

Investigation Workflow:

  1. Load and Decode:

    • Use Registry Explorer (automatic decoding)

    • Or manually decode ROT13 values

  2. Sort by Last Run Time:

  3. Filter Suspicious Executables:

  4. Check Run Counts:

Red Flags:

Example Analysis:

Pro Tips:

βœ… GUI Only: Only tracks programs with GUI (not console applications)

βœ… Persistence: Survives file deletion

βœ… Focus Time: Helps distinguish user interaction vs. automated execution

⚠️ Encoding: ROT13 is obfuscation, not encryption


πŸ“… Windows Timeline Analysis

Overview

  • Feature: Windows 10 Timeline (deprecated in late Win10/Win11)

  • Database: SQLite (ActivitiesCache.db)

  • Location: Per-user profile

  • Retention: 30 days

  • Status: Feature deprecated but database still populated

Key Information Available

Data Point
Description
Forensic Value

Application

Program executed

Activity identification

Start Time

Activity start

Timeline

End Time

Activity end

Duration calculation

Duration

How long active

Usage analysis

Files/URLs

Items opened

Content accessed

Expiration Time

Record expiry

Data retention

Location

Collection & Analysis

Collection:

Using WxTCmd (Windows Timeline Parser):

Using DB Browser for SQLite:

Useful SQL Queries:

Analysis Tips

Investigation Workflows:

1. Timeline Reconstruction:

2. Document Access Analysis:

3. Web Browsing History:

4. Application Usage Patterns:

Red Flags:

Pro Tips:

βœ… JSON Payloads: OriginalPayload column contains rich JSON data

βœ… Cross-Platform: Can sync across devices (Microsoft account)

βœ… Persistence: Survives after feature deprecation

⚠️ Privacy: Users can disable/clear timeline


πŸ“Š SRUM Analysis

Overview

  • Name: System Resource Usage Monitor

  • Purpose: Track application resource usage, network activity

  • Location: C:\Windows\System32\sru\SRUDB.dat

  • Format: ESE database

  • Retention: 30-60 days

Key Information Available

Data Point
Description
Forensic Value

Network Usage

Bytes sent/received per app

Data exfiltration

Application Resource

CPU, memory usage

Resource analysis

Application Timeline

When apps ran

Execution timeline

Network Connectivity

Connected networks

Connection history

Energy Usage

Battery/power usage

Mobile device analysis

User Activity

Per-user stats

User behavior

Important Tables

Collection & Analysis

Collection (Requires Both Files):

Using SrumECmd:

Using FTK Imager to Extract:

Analysis Tips

Investigation Workflows:

1. Network Data Usage Analysis:

2. Application Resource Usage:

3. Timeline of Network Activity:

4. Data Exfiltration Detection:

5. Per-User Activity:

Red Flags:

Investigation Scenarios:

Scenario: Data Exfiltration

Scenario: Resource Abuse

Pro Tips:

βœ… Hourly Granularity: Data recorded per hour

βœ… User Context: Tracks which user ran what

βœ… Network Interfaces: Can identify VPN, WiFi, Ethernet usage

⚠️ SOFTWARE Hive Required: App GUIDs mapped to names via registry


πŸ“ MRU Analysis

Overview

  • MRU: Most Recently Used

  • Purpose: Track recent file/folder access per application

  • Location: NTUSER.DAT (per user)

  • Retention: Varies by MRU type (typically 10-20 items)

Key MRU Locations

Registry Path
Description

RecentDocs

Recently opened documents (all file types)

ComDlg32\LastVisitedPidlMRU

Last folders accessed by applications

ComDlg32\OpenSavePidlMRU

Files accessed via Open/Save dialogs

RunMRU

Commands typed in Run dialog

TypedPaths

Paths typed in Explorer address bar

WordWheelQuery

Windows search terms

Office MRU

Recent documents per Office app

Detailed Locations

Collection & Analysis

Using Registry Explorer:

Using RegRipper:

Manual Registry Query (Live System):

Analysis Tips

Investigation Workflows:

1. Recent Document Analysis:

2. Application File Access:

3. Command Execution History:

4. Search Terms:

Red Flags:

Pro Tips:

βœ… MRU Order: List maintained in chronological order (most recent first)

βœ… Persistence: Survives file/folder deletion

βœ… Per-User: Each user has separate MRU data

⚠️ Privacy: Some applications clear their MRU


πŸ’» PowerShell History

Overview

  • Feature: PSReadLine console history

  • Location: Per-user AppData

  • Format: Plain text file

  • Retention: Last 4,096 commands

  • Available: PowerShell v5+ (Win10/Server 2016+)

Location

Key Information Available

Data Point
Description
Forensic Value

Commands

Exact commands typed

Attack reconstruction

Parameters

Full command syntax

Technique identification

Order

Chronological sequence

Timeline

Scripts

Inline scripts executed

Malware analysis

CRITICAL Understanding

Collection & Analysis

Collection:

Analysis:

Timeline Analysis:

Analysis Tips

Investigation Workflows:

1. Command Reconstruction:

2. Credential Access:

3. Lateral Movement:

4. Download Cradle:

5. Obfuscation:

Red Flags:

Evasion Detection:

Pro Tips:

βœ… Plain Text: Easy to read and analyze

βœ… Persistent: Not cleared automatically

βœ… Comprehensive: Captures full command syntax

⚠️ Limitations: Console only (not ISE, not script files)

⚠️ Timestamps: File modification time = last command time (not per-command timestamps)


πŸ—„οΈ NTFS Artifacts

Master File Table ($MFT)

Overview:

  • Purpose: Database of all files/folders on NTFS volume

  • Location: NTFS root (hidden system file)

  • Contains: Metadata for every file/directory

Key Information:

  • File name

  • File size

  • Timestamps (MACB - Modified, Accessed, Changed, Born)

  • MFT entry number

  • Parent MFT entry

  • Attributes (resident/non-resident data)

Collection:

Analysis:

Using MFTExplorer (GUI):

Investigation Use Cases:


UsnJrnl ($J)

Overview:

  • Purpose: Change journal for NTFS volume

  • Location: NTFS\$Extend\$RmMetadata\$UsnJrnl\$J

  • Contains: Records of file system changes

Key Information:

  • File name

  • Reason for change (create, delete, rename, modify)

  • Timestamp of change

  • MFT entry and parent entry

  • Change sequence number (USN)

Collection:

Analysis:

Investigation Use Cases:

Red Flags:


$LogFile

Overview:

  • Purpose: Transaction log for NTFS metadata operations

  • Location: NTFS root

  • Contains: Redo/undo information for transactions

Key Information:

  • File operations (create, delete, rename, modify)

  • Timestamps

  • MFT entry references

  • Operation details

Collection:

Analysis:

Investigation Use Cases:


Alternate Data Streams (ADS)

Overview:

  • Purpose: Store multiple data streams in single file

  • Feature: Hidden from normal directory listings

  • Risk: Can hide malware

Common ADS:

Detection:

Analysis:

Red Flags:

Execution from ADS:


πŸ“š Investigation Playbooks

Playbook 1: Malware Execution Investigation

Objective: Confirm malware execution and build timeline

Phase 1: Initial Identification (15 min)

Phase 2: Execution Proof (30 min)

Phase 3: User Activity (30 min)

Phase 4: Timeline Construction (45 min)

Phase 5: Persistence Check (30 min)

Phase 6: Impact Assessment (45 min)

Phase 7: Reporting (30 min)


Playbook 2: Data Exfiltration Investigation

Objective: Detect and quantify data exfiltration

Phase 1: Indicators (15 min)

Phase 2: Network Activity Analysis (45 min)

Phase 3: File Access Analysis (45 min)

Phase 4: USB/External Media (30 min)

Phase 5: Staging Detection (30 min)

Phase 6: Cloud/Email Exfil (30 min)

Phase 7: Quantification (30 min)


Playbook 3: Attacker Tool Usage

Objective: Identify what tools attacker used

Phase 1: Known Tool Detection (30 min)

Phase 2: PowerShell Analysis (45 min)

Phase 3: Execution Context (30 min)

Phase 4: Tool Downloaded (30 min)

Phase 5: Tool Persistence (30 min)


πŸ› οΈ Tool Reference

Eric Zimmerman Tools

Download: https://ericzimmerman.github.io/

Installation:


NirSoft Tools

Download: https://www.nirsoft.net/


Sysinternals Tools

Download: https://live.sysinternals.com/


KAPE

Download: https://www.kroll.com/kape


FTK Imager

Download: https://www.exterro.com/ftk-imager

Use for:

  • Collecting locked files (SRUM, Amcache)

  • Extracting $MFT, $J, $LogFile

  • Forensic image mounting


DB Browser for SQLite

Download: https://sqlitebrowser.org/

Use for:

  • Windows Timeline analysis

  • Other SQLite databases


πŸŽ“ Quick Reference Cards

Artifact Comparison Matrix

Artifact
Proves Execution
Last Run Time
Run Count
Historical Times
File Hash
Retention

Prefetch

βœ… Yes

βœ… Yes

βœ… Yes

βœ… 8 times (Win10+)

❌ No

1,024 files

BAM/DAM

⚠️ Likely

βœ… Yes

❌ No

❌ No

❌ No

~7 days

ShimCache

❌ No (Win10+)

❌ No

❌ No

❌ No

❌ No

1,024 entries

Amcache

⚠️ Presence

⚠️ Modified

❌ No

❌ No

βœ… SHA1

Long-term

UserAssist

βœ… GUI only

βœ… Yes

βœ… Yes

❌ No

❌ No

Persistent

Jump Lists

⚠️ Indirect

βœ… Yes

❌ No

❌ No

❌ No

~2,000/app

Timeline

⚠️ Activity

βœ… Yes

❌ No

βœ… Yes

❌ No

30 days

SRUM

⚠️ Resource

βœ… Yes

❌ No

βœ… Hourly

❌ No

30-60 days


Collection Priority Checklist

Live System - First 15 Minutes:

Live System - Next 30 Minutes:

Live System - Next 30 Minutes:

Forensic Image - Priority Order:


Use this guide as your go-to reference for program execution investigations. Combine multiple artifacts for the strongest evidence.

Last updated