SlideShare a Scribd company logo
**** it, Do It Live!
(PowerShell Digital Forensics)
Jared Atkinson
Veris Group’s Adaptive Threat Division
Special Thanks
○This tool and presentation would not be possible
if it wasn’t for the help and phenomenal work
from these people:
□Matt Graeber (PowerShell Wizardry)
□Richard Russon (Linux-NTFS Project)
□Joachim Metz (Libyal Project)
□Jeff Bryner (NBDServer)
□Carlos Perez (PowerShell Binary Module)
□David Cowan (NTFS Triforce)
□Ange Albertini (Corkami)
□Phil Polstra (Linux Forensics)
□James Habben (NTFS Fixup Values)
@jaredcatkinson
○Jared Atkinson
□Hunt Capability Lead for Adaptive Threat Division
○ Leads the service line responsible for proactive detection
and response to advanced threats in Fortune 100
commercial environments
□2015 Black Hat Minesweeper Champion
□Moderator of the PowerShell.com “Security Forum”
□Developer of PowerForensics, Uproot IDS, and
WMIEventing
□Researcher of forensic artifact file formats
□History
○ U.S. Air Force Hunt (2011 - 2015)
○ GCFA, GCWN, GREM, etc.
Hunting
Philosophy
To Hunt, or not to Hunt...
Intrusions
Cyber Kill Chain
○F2T2EA
□Find, Fix, Target, Track, Engage, Assess
○Adapted from Lockheed Martin White Paper
○Any broken link will affect the entire chain
Prevention
○Prevailing Network Defense Concept for much
of the 90s and 2000s
○Goal of stopping attacks at the perimeter
□ Glory years of “Server Side Exploits”
○Largely failed due to rise in the popularity of
“Client Side”attacks
“...more than two-thirds of [Cyber Espionage]
incidents ... have featured phishing.” -Verizon
Incident Response
○Early 2000s to mid 2010s
○“Five Alarm Fire” Concept
○Kicked off by:
□Network security monitoring alerts
□Third party notification
□Public disclosure
○By the time you notice it is often too late
Hunting
○Concept originating in the US DoD
○Practice “Assume Breach” mentality
○Detection, Investigation, Response
□Deny, Degrade, Disrupt, Manipulate
“Fundamentally, if somebody wants to get in, they're getting in… Accept
that… What we tell clients is:
Number one, you're in the fight, whether you thought you were or not.
Number two, you're almost certainly are penetrated.”
Michael Hayden
Former Director of CIA & NSA
Evolution of
Forensics
“Intelligence is based on how efficient a
species became at doing the things they
need to survive.” -Charles Darwin
Investigation
Evolution
Image
Collection
Scripts
Live
Response
Image
○Analyst takes an infected machine offline, make
a hard drive image (bit for bit copy) and perform
forensic analysis
○Pros
□“Gold” Standard over past 2+ decades
□Repeatable results
□Allows for thorough analysis
○Cons
□Lose all volatile data
□Slow/non-scalable
Collection Scripts
○Analyst uses a script to collect forensically
relevant files often using third party binaries to
access certain files
□First step in automating DFIR processes
○Pros
□Speed
□Scalability
○Cons
□Often Messy (Not Forensically Sound)
□Third party dependencies (File Access, Artifact Parsing,
Remote support)
□Analysis done in vacuum
Live Response
○Analyst quickly triages key file system artifacts
in a forensically sound manner
□Merges some of the best attributes of Imaging and
Collection Scripts
□“Intelligent” Analysis – Where the analysis of one artifact
points the analyst in the direction of another
○Pros
□Speed/Scalability
□Forensically Sound
□Self contained
○Cons
□Repeatability
Response
PowerForensics
Old Dog, New Tricks
Detection Investigation
What is PowerShell
○Task-based command-line shell and
scripting language
○Built on the .NET Framework
□Cmdlets for performing common system
administration tasks
□Consistent design
□Powerful object manipulation capabilities
□Extensible interface (Modules)
○ Independent software vendors and enterprise developers can
build custom tools and utilities to administer their software.
□Full access to the Windows API
Requirements
○Centralized forensic toolset
○Forensically sound
□Parse raw disk structures
□Don’t alter NTFS timestamps
○Can execute on a live (running) host
○Operationally fast
□Collect forensic data in seconds or minutes
○Modular capabilities
□Cmdlets perform discrete tasks and can be tied
together for more complicated tasks
○Capable of working remotely
□At the proof of concept stage
Forensics Toolbox
What is Forensically
Sound?
“A forensically sound duplicate is obtained in a manner that does
not materially alter the source evidence, except to the minimum
extent necessary to obtain the evidence. The manner used to
obtain the evidence must be documented, and should be
justified to the extent applicable.” - Richard Bejtlich and Harlan
Carvey
BSidesDC - **** it, Do It Live (PowerShell Digital Forensics)
BSidesDC - **** it, Do It Live (PowerShell Digital Forensics)
BSidesDC - **** it, Do It Live (PowerShell Digital Forensics)
Fast?!?
Get-BootSector
Boot Sector
Get-MBR Get-GPT
Get-PartitionTable
NTFS Structures
Get-VolumeBootRecord
Get-FileRecord
Get-FileRecordIndex
NTFS System Files
Get-AttrDef Get-BadClus Get-Bitmap
Get-UsnJrnlGet-UsnJrnlInformation
Get-VolumeInformation Get-VolumeName
Windows Registry
Get-RegistryKey
Get-Amcache Get-NetworkList
Get-Timezone Get-UserAssist
Get-RegistryValue
Utility Cmdlets
Copy-FileRaw
Get-AlternateDataStream
Get-ChilditemRaw
Get-ContentRaw
Get-Prefetch Get-ScheduledJobRaw
Invoke-DD
Linux Support
Get-Superblock
Get-BlockGroupDescriptor
Get-Inode
Investigation Demo
My sacrifice to the demo gods…
Notification
○Time: 13 October 2015 18:31 UTC
○Hostname: WIN-KFGTOETNIFJ
○IP Address: 10.20.3.187
○Activity Description:
□At 18:31 UTC on 13 Oct 2015 a machine with IP
of 10.20.3.187 called out to a previously unseen
IP address of 10.20.3.191 (pretend this is a
domain :-D) over port 80. During this and a
number of additional connections analysts noticed
a sizeable amount of data transferred from the
internal asset to an external system (10.20.3.191).
Investigation Demo
https://youtu.be/YaYhl6c3S2U
File Recovery
Demo
https://youtu.be/0vndpNbWbIw
Report
○Time: 13 October 2015 18:30 - 18:38 UTC
○At job to elevate to SYSTEM context
□Executed launcher.bat
○Implant appeared to use some combination of
PowerShell and WMI in implant
○Created staging directory named “exfil”
○Compressed three files to create an archive
called exfil.zip (which we recovered)
□hamburgerrecipes.txt
□finances.csv
□password.txt
Attack Demo
https://youtu.be/aZxnIUOwb6E
The Future
The Shiny Shiny Future
Moving Forward
○More artifacts!!
□ESE database support (SRUM, NTDS.dit, etc.)
○Support for alternate file systems
□Windows: FAT12, FAT16, FAT32, exFAT
□Linux: Ext2, Ext3, Ext4
□Mac: HFS+
○Online documentation (Open API)
○Community Involvement!!!
○Organic Remoting
□Network Block Device (NBD) to the rescue
@jaredcatkinson
https://github.com/Invoke-IR/PowerForensics
https://github.com/Invoke-IR/PowerForensics_Source
Any questions?

More Related Content

PPTX
44CON London 2015: Old Dog, New Tricks: Forensics with PowerShell
PPTX
44CON London 2015: NTFS Analysis with PowerForensics
PPTX
Blackhat 2018 - The New Pentest? Rise of the Compromise Assessment
PPTX
Unmasking Careto through Memory Forensics (video in description)
PPTX
BSidesLV 2016 - Powershell - Hunting on the Endpoint - Gerritz
PPTX
Introduction to Dynamic Malware Analysis ...Or am I "Cuckoo for Malware?"
PPTX
Memory Forensics: Defeating Disk Encryption, Skilled Attackers, and Advanced ...
PPTX
First Responders Course - Session 7 - Incident Scope Assessment [2004]
44CON London 2015: Old Dog, New Tricks: Forensics with PowerShell
44CON London 2015: NTFS Analysis with PowerForensics
Blackhat 2018 - The New Pentest? Rise of the Compromise Assessment
Unmasking Careto through Memory Forensics (video in description)
BSidesLV 2016 - Powershell - Hunting on the Endpoint - Gerritz
Introduction to Dynamic Malware Analysis ...Or am I "Cuckoo for Malware?"
Memory Forensics: Defeating Disk Encryption, Skilled Attackers, and Advanced ...
First Responders Course - Session 7 - Incident Scope Assessment [2004]

What's hot (20)

PDF
De-Anonymizing Live CDs through Physical Memory Analysis
PPTX
Purpose Driven Hunt (DerbyCon 2017)
PDF
Forensics perspective ERFA-møde marts 2017
PDF
Linux Memory Analysis with Volatility
PPTX
OMFW 2012: Analyzing Linux Kernel Rootkits with Volatlity
PDF
Thotcon 0x5 - Retroactive Wiretapping VPN over DNS
PDF
The day I ruled the world (RootedCON 2020)
ODP
Malware analysis - What to learn from your invaders
PPTX
International collaborative efforts to share threat data in a vetted member c...
PDF
THOTCON 0x6: Going Kinetic on Electronic Crime Networks
PPTX
Catching fileless attacks
PPTX
Remnux tutorial-1 Statically Analyse Portable Executable(PE) Files
PDF
Initial Response and Forensic Duplication
PPTX
Malware Static Analysis
PPT
Live Memory Forensics on Android devices
PDF
LTEC 2013 - EnCase v7.08.01 presentation
PDF
Using Algorithms to Brute Force Algorithms...A Journey Through Time and Names...
PDF
End-to-End Analysis of a Domain Generating Algorithm Malware Family
PPTX
Rooted2020 roapt evil-mass_storage_-_tu-ya_aqui_-_david_reguera_-_abel_valero
PPT
Digital Forensic Tools - Application Specific.
De-Anonymizing Live CDs through Physical Memory Analysis
Purpose Driven Hunt (DerbyCon 2017)
Forensics perspective ERFA-møde marts 2017
Linux Memory Analysis with Volatility
OMFW 2012: Analyzing Linux Kernel Rootkits with Volatlity
Thotcon 0x5 - Retroactive Wiretapping VPN over DNS
The day I ruled the world (RootedCON 2020)
Malware analysis - What to learn from your invaders
International collaborative efforts to share threat data in a vetted member c...
THOTCON 0x6: Going Kinetic on Electronic Crime Networks
Catching fileless attacks
Remnux tutorial-1 Statically Analyse Portable Executable(PE) Files
Initial Response and Forensic Duplication
Malware Static Analysis
Live Memory Forensics on Android devices
LTEC 2013 - EnCase v7.08.01 presentation
Using Algorithms to Brute Force Algorithms...A Journey Through Time and Names...
End-to-End Analysis of a Domain Generating Algorithm Malware Family
Rooted2020 roapt evil-mass_storage_-_tu-ya_aqui_-_david_reguera_-_abel_valero
Digital Forensic Tools - Application Specific.
Ad

Viewers also liked (20)

PPTX
PowerShell - PowerForensics
PPTX
Lateral Movement with PowerShell
PDF
(160820) #fitalk fileless malware forensics
PPTX
5 of 13 Ways To Prevent Advanced Persistent Threads (APTs)
PDF
(140716) #fitalk 전자금융사고에서의 디지털 포렌식
PDF
IEF for Military and Government
PDF
P Hundamental Security Coding Secure With Php Lamp
PPTX
Cyber forensics 02 mit-2014
PDF
(140118) #fitalk 2013 e-discovery trend
PPT
Logs for Information Assurance and Forensics @ USMA
PDF
(141031) #fitalk plaso 슈퍼 타임라인 분석 도구 활용 방안
PDF
06 Computer Image Verification and Authentication - Notes
PDF
Extracting and Decoding Smartphone and Tablet Evidence with the UFED Series: ...
PDF
Sued or Suing: Introduction to Digital Forensics
PDF
(Fios#03) 4. 파워셸 포렌식 조사 기법
PPTX
Autopsy 3: Free Open Source End-to-End Windows-based Digital Forensics Platform
PDF
05 Duplication and Preservation of Digital evidence - Notes
PDF
I Have the Power(View)
PDF
File000120
PDF
04 Evidence Collection and Data Seizure - Notes
PowerShell - PowerForensics
Lateral Movement with PowerShell
(160820) #fitalk fileless malware forensics
5 of 13 Ways To Prevent Advanced Persistent Threads (APTs)
(140716) #fitalk 전자금융사고에서의 디지털 포렌식
IEF for Military and Government
P Hundamental Security Coding Secure With Php Lamp
Cyber forensics 02 mit-2014
(140118) #fitalk 2013 e-discovery trend
Logs for Information Assurance and Forensics @ USMA
(141031) #fitalk plaso 슈퍼 타임라인 분석 도구 활용 방안
06 Computer Image Verification and Authentication - Notes
Extracting and Decoding Smartphone and Tablet Evidence with the UFED Series: ...
Sued or Suing: Introduction to Digital Forensics
(Fios#03) 4. 파워셸 포렌식 조사 기법
Autopsy 3: Free Open Source End-to-End Windows-based Digital Forensics Platform
05 Duplication and Preservation of Digital evidence - Notes
I Have the Power(View)
File000120
04 Evidence Collection and Data Seizure - Notes
Ad

Similar to BSidesDC - **** it, Do It Live (PowerShell Digital Forensics) (20)

PPTX
44CON London 2015 - Old Dog, New Tricks: Forensics With PowerShell
PPTX
Windows Live Forensics 101
PPTX
Msra 2011 windows7 forensics-troyla
PPTX
Power forensics
PDF
CNIT 121: 11 Analysis Methodology
PDF
11 Analysis Methodology
PPTX
Leveraging NTFS Timeline Forensics during the Analysis of Malware
PPT
Electornic evidence collection
PPT
Intrusion Discovery on Windows
PPTX
DR FAT
PPTX
Adversary tactics config mgmt-&-logs-oh-my
PDF
MNSEC 2018 - Windows forensics
PDF
the Cyber - Forensics - Lab - Manual . pdf
PDF
Memory forensics and incident response
PDF
Nazar Tymoshyk et al - Night in Defense Workshop: Hunting for a needle in a h...
PPT
CF.ppt
PPTX
cyber Forensics
PDF
Leveraging Digital Forensics | Patricia Watson
PDF
CNIT 121: 3 Pre-Incident Preparation
PPT
Role of a Forensic Investigator
44CON London 2015 - Old Dog, New Tricks: Forensics With PowerShell
Windows Live Forensics 101
Msra 2011 windows7 forensics-troyla
Power forensics
CNIT 121: 11 Analysis Methodology
11 Analysis Methodology
Leveraging NTFS Timeline Forensics during the Analysis of Malware
Electornic evidence collection
Intrusion Discovery on Windows
DR FAT
Adversary tactics config mgmt-&-logs-oh-my
MNSEC 2018 - Windows forensics
the Cyber - Forensics - Lab - Manual . pdf
Memory forensics and incident response
Nazar Tymoshyk et al - Night in Defense Workshop: Hunting for a needle in a h...
CF.ppt
cyber Forensics
Leveraging Digital Forensics | Patricia Watson
CNIT 121: 3 Pre-Incident Preparation
Role of a Forensic Investigator

Recently uploaded (20)

DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Approach and Philosophy of On baking technology
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Machine learning based COVID-19 study performance prediction
PDF
Electronic commerce courselecture one. Pdf
PPT
Teaching material agriculture food technology
PPTX
MYSQL Presentation for SQL database connectivity
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
The AUB Centre for AI in Media Proposal.docx
sap open course for s4hana steps from ECC to s4
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
20250228 LYD VKU AI Blended-Learning.pptx
Approach and Philosophy of On baking technology
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Per capita expenditure prediction using model stacking based on satellite ima...
Machine learning based COVID-19 study performance prediction
Electronic commerce courselecture one. Pdf
Teaching material agriculture food technology
MYSQL Presentation for SQL database connectivity
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Programs and apps: productivity, graphics, security and other tools
Reach Out and Touch Someone: Haptics and Empathic Computing
MIND Revenue Release Quarter 2 2025 Press Release
Digital-Transformation-Roadmap-for-Companies.pptx
Advanced methodologies resolving dimensionality complications for autism neur...
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf

BSidesDC - **** it, Do It Live (PowerShell Digital Forensics)