SlideShare a Scribd company logo
1 of 29
Download to read offline
Malicious File for Exploiting
Forensic Software
Takahiro Haruyama / Hiroshi Suzuki
Internet Initiative Japan Inc.
• Forensic Investigator & Malware Analyst @
Internet Initiative Japan
• Presentations
– SANS DFIR Summit, Blackhat EU, RSA Conference
Japan, etc..
• Hands-ons
– CEIC, FIRST TC Kyoto/Lisbon, etc..
• Tools
– EnCase EnScript, IDAPython script, etc..
– http://cci.cocolog-nifty.com/blog/
• EnCase Certified Examiner since 2009
• twitter: @cci_forensics
Who am I?
• Background
• Fuzzing Oracle Outside In
• Anti-forensics by exploiting bugs
• Countermeasures
• Wrap-up
Overview
Background
• Forensic software needs a function
viewing file content
– Most commercial tools adopt the same
library
• e.g., EnCase, FTK, X-Ways, etc..
• Oracle Outside In Technology [1]
– analyze/extract/convert over 500 different
file types data
– also used by enterprise software
• e.g., Microsoft Exchange, Cisco Security Agent,
IBM OmniFind Enterprise Edition, McAfee
GroupShield, Symantec Enterprise Vault
File Viewer in Forensic Software
• Several bugs of Oracle Outside In were
reported last year [2]
• If still exploitable, lots of forensic
investigators are exposed to risks when
viewing/processing crafted malicious files
– process hang-up
– other anti-forensic techniques
• e.g., data alternation or hiding, evidence deletion
– malware infection with privilege
• e.g., owning forensic workstations for government
organizations 
• Researched about the exploitability
Motivation
Fuzzing Oracle Outside In
• The fuzzer using EnCase
– MiniFuzz [3]
– EnCase EnScript
– kernel driver
Fuzzer Implementation
EnCase
EnCase EnScript
MiniFuzz
Kernel Driver
mutate files & run EnCase
prevent
detection
call Outside In function
• EnScript methods calling Outside In
– DocumentClass
• GetDocView
– Returns a list containing one image for each page in
the document
• WriteTranscript
– Returns a text extracted from the document
• One pitfall
– EnScript can’t receive command-line
arguments
• Use 3rd party tool [4]
EnScript for Fuzzer
Check the Result
Anti-forensics by exploiting
bugs
• Two examples
– Process hang-up using infinite loop DoS
vulnerability
– Arbitrary code execution using heap overflow
vulnerability
• Tested Outside In versions (latest: 8.4.1)
– 8.3.5 on EnCase 6
• To tell the truth, most EnCase users prefer 6 to 7 
– 8.3.7 on X-Ways Forensics
• X-Ways recommends 8.3.7 instead of 8.4.1 for web
history examination
– 8.4.0 on EnCase 7
Anti-forensics by exploiting
bugs
• Included in the function parsing Hangul Word
Processor format document
– A malicious file can cause infinite loop in
vshwp2.dll
• JVN#68663052 [5] (CVE-2013-3776 [6])
– Affected version: 8.4.1 and earlier
– Resolved on July 16th, 2013 [7]
Process Hang-up using Infinite
Loop DoS Vulnerability
• 8.4.0 on EnCase 7
Demo
• Included in the
function parsing
Ichitaro format
document
– A malicious file can
overwrite heap
chunks
• JVN#07497769 [8]
(CVE-2013-3781 [9])
– Affected version:
8.3.7 and earlier
– Resolved on July
16th, 2013 [7]
Arbitrary Code Execution using
Heap Overflow Vulnerability
• Vista or later Windows OS adopt various
mitigation techniques to prevent an
exploitation of heap overflow [10]
– Look-aside lists have been replaced by the Low
Fragmentation Heap (LFH)
– heap entry metadata randomization
– randomized heap base address
– etc...
• One promising method is overwriting function
pointers in heap chunks
– But the offset values to them are not constant
Overwriting Function Pointers
• Heap spraying is a payload delivery
technique
– It allows us to put our shellcodes at a
predictable address (e.g., 0x0c0c0c0c)
• We need to fill chunks of memory in the
heap before gaining control over EIP
• How?
– Javascript or vbscript in web browsers
– Javascript or ActionScript in Adobe Reader
– ? in forensic software
Heap Spraying
• Bitmap heap spraying [11] is an effective
technique because forensic investigators
often examine image files
• Most forensic software supports
displaying several images at the same
time
– EnCase
• “Bookmark Page as Image” in Doc view
• Make the bookmarked images “set-included”
– X-Ways Forensics
• Double-click image files
Heap Spraying with Bitmap
Images
Heap Spraying with Bitmap
Images: Example on EnCase 6
• 8.3.5 on EnCase 6
• 8.3.7 on X-Ways Forensics
Demo
• Not necessarily succeed
– Function pointers called in a short time
should be included in overwritten area
• e.g., sccch/sccut/sccvw, ole32, etc..
– current success probability
• EnCase 6
– 40-50%
• X-Ways
– 10-20%
– To improve the probability, we need to
manipulate heap chunk layout before
causing overflow 
Success Probability of the Heap
Overflow Exploitation
Countermeasures
• Developers should
– check buffer boundary to prevent overflow
– enable “HeapEnableTerminateOnCorruption“
• Use HeapSetInformation [12] API
• If a heap corruption detected, the process terminates
immediately
– 0xc0000374 (STATUS_HEAP_CORRUPTION)
Prevention of Arbitrary Code
Execution using Heap Overflow
• Disable the operation for bitmap heap spray
– EnCase 6
• [Tools] -> [Options] -> [Global]
• uncheck “Enable Pictures in Doc View”
– X-Ways Forensics
• [Options] -> [Viewer Programs]
• uncheck “For pictures, too”
Heap spray Prevention
• Use the latest version
– 8.4.0 or later seems to fix most bugs
discovered by my fuzzer
• Do not use EnCase 6 / X-Ways with 8.3.7
• Do not install file viewer
– We can install EnCase/X-Ways without
Outside In
• Configure for using native applications (e.g.,
Microsoft Word for doc/docx files)
• Configure for exploit mitigation [13]
– e.g., EMET, AppLocker, etc...
Common Countermeasures
Wrap-up
• Know the risk when examining unknown files
acquired in forensic investigation
– The file viewer component is fragile
• Several bugs still remain in the old version (e.g., .doc)
– Investigators should pay attention to the
security settings of their workstations
• Forensic software vendors tend to use an old
version of the component
– They should update their products as soon as
the latest version of Outside In is released
– Much the same is true on enterprise software
Wrap-up
28
Questions?
(twitter: @cci_forensics)
Please scan your badges for
evaluation surveys!
[1] Oracle Outside In Technology
<http://www.oracle.com/us/technologies/embedded/025613.htm>
[2] Oracle Outside In contains multiple exploitable vulnerabilities
<https://www.kb.cert.org/vuls/id/118913>
[3] SDL MiniFuzz File Fuzzer
<http://www.microsoft.com/en-us/download/details.aspx?id=21769>
[4] Command Line DLL.zip <http://www.swiftforensics.com/p/downloads.html>
[5] JVN#68663052 Oracle Outside In vulnerable to denial-of-service (DoS)
<http://jvn.jp/en/jp/JVN68663052/index.html>
[6] CVE-2013-3776 <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-3776>
[7] Oracle Critical Patch Update Advisory - July 2013
<http://www.oracle.com/technetwork/topics/security/cpujuly2013-1899826.html>
[8] JVN#07497769 Oracle Outside In vulnerable to buffer overflow
<http://jvn.jp/en/jp/JVN07497769/index.html>
[9] CVE-2013-3781 <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-3781>
[10] Preventing the exploitation of user mode heap corruption vulnerabilities
<http://blogs.technet.com/b/srd/archive/2009/08/04/preventing-the-exploitation-of-user-
mode-heap-corruption-vulnerabilities.aspx>
[11] Exploit writing tutorial part 11 : Heap spraying Demystified
<https://www.corelan.be/index.php/2011/12/31/exploit-writing-tutorial-part-11-heap-
spraying-demystified/>
[12] HeapSetInformation function
<http://msdn.microsoft.com/en-us/library/windows/desktop/aa366705(v=vs.85).aspx>
[13] Forensics Software and Oracle Outside In
<https://www.cert.org/blogs/certcc/2013/07/forensics_software_and_oracle.html>
29
References

More Related Content

What's hot

REMnux tutorial-2: Extraction and decoding of Artifacts
REMnux tutorial-2: Extraction and decoding of ArtifactsREMnux tutorial-2: Extraction and decoding of Artifacts
REMnux tutorial-2: Extraction and decoding of ArtifactsRhydham Joshi
 
Captain Hook: Pirating AVs to Bypass Exploit Mitigations
Captain Hook: Pirating AVs to Bypass Exploit MitigationsCaptain Hook: Pirating AVs to Bypass Exploit Mitigations
Captain Hook: Pirating AVs to Bypass Exploit MitigationsenSilo
 
Remnux tutorial-1 Statically Analyse Portable Executable(PE) Files
Remnux tutorial-1  Statically Analyse Portable Executable(PE) FilesRemnux tutorial-1  Statically Analyse Portable Executable(PE) Files
Remnux tutorial-1 Statically Analyse Portable Executable(PE) FilesRhydham Joshi
 
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...Sam Bowne
 
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static Techniques
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static TechniquesCNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static Techniques
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static TechniquesSam Bowne
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgSam Bowne
 
Malware Analysis and Defeating using Virtual Machines
Malware Analysis and Defeating using Virtual MachinesMalware Analysis and Defeating using Virtual Machines
Malware Analysis and Defeating using Virtual Machinesintertelinvestigations
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgSam Bowne
 
Practical Malware Analysis Ch12
Practical Malware Analysis Ch12Practical Malware Analysis Ch12
Practical Malware Analysis Ch12Sam Bowne
 
Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Rhydham Joshi
 
Fuzzing the Media Framework in Android
Fuzzing the Media Framework in AndroidFuzzing the Media Framework in Android
Fuzzing the Media Framework in AndroidE Hacking
 
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs Sam Bowne
 
Investigating Hackers' Tools
Investigating Hackers' ToolsInvestigating Hackers' Tools
Investigating Hackers' ToolsIsrael Umana
 
Practical Malware Analysis Ch13
Practical Malware Analysis Ch13Practical Malware Analysis Ch13
Practical Malware Analysis Ch13Sam Bowne
 
Metasploit & Windows Kernel Exploitation
Metasploit & Windows Kernel ExploitationMetasploit & Windows Kernel Exploitation
Metasploit & Windows Kernel ExploitationzeroSteiner
 
Injection on Steroids: Codeless code injection and 0-day techniques
Injection on Steroids: Codeless code injection and 0-day techniquesInjection on Steroids: Codeless code injection and 0-day techniques
Injection on Steroids: Codeless code injection and 0-day techniquesenSilo
 
CNIT 126 12: Covert Malware Launching
CNIT 126 12: Covert Malware LaunchingCNIT 126 12: Covert Malware Launching
CNIT 126 12: Covert Malware LaunchingSam Bowne
 
IDA Vulnerabilities and Bug Bounty  by Masaaki Chida
IDA Vulnerabilities and Bug Bounty  by Masaaki ChidaIDA Vulnerabilities and Bug Bounty  by Masaaki Chida
IDA Vulnerabilities and Bug Bounty  by Masaaki ChidaCODE BLUE
 
Practical Malware Analysis: Ch 8: Debugging
Practical Malware Analysis: Ch 8: Debugging Practical Malware Analysis: Ch 8: Debugging
Practical Malware Analysis: Ch 8: Debugging Sam Bowne
 
Process injection - Malware style
Process injection - Malware styleProcess injection - Malware style
Process injection - Malware styleSander Demeester
 

What's hot (20)

REMnux tutorial-2: Extraction and decoding of Artifacts
REMnux tutorial-2: Extraction and decoding of ArtifactsREMnux tutorial-2: Extraction and decoding of Artifacts
REMnux tutorial-2: Extraction and decoding of Artifacts
 
Captain Hook: Pirating AVs to Bypass Exploit Mitigations
Captain Hook: Pirating AVs to Bypass Exploit MitigationsCaptain Hook: Pirating AVs to Bypass Exploit Mitigations
Captain Hook: Pirating AVs to Bypass Exploit Mitigations
 
Remnux tutorial-1 Statically Analyse Portable Executable(PE) Files
Remnux tutorial-1  Statically Analyse Portable Executable(PE) FilesRemnux tutorial-1  Statically Analyse Portable Executable(PE) Files
Remnux tutorial-1 Statically Analyse Portable Executable(PE) Files
 
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...
Practical Malware Analysis: Ch 0: Malware Analysis Primer & 1: Basic Static T...
 
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static Techniques
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static TechniquesCNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static Techniques
CNIT 126 Ch 0: Malware Analysis Primer & 1: Basic Static Techniques
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbg
 
Malware Analysis and Defeating using Virtual Machines
Malware Analysis and Defeating using Virtual MachinesMalware Analysis and Defeating using Virtual Machines
Malware Analysis and Defeating using Virtual Machines
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbg
 
Practical Malware Analysis Ch12
Practical Malware Analysis Ch12Practical Malware Analysis Ch12
Practical Malware Analysis Ch12
 
Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1
 
Fuzzing the Media Framework in Android
Fuzzing the Media Framework in AndroidFuzzing the Media Framework in Android
Fuzzing the Media Framework in Android
 
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs
Practical Malware Analysis: Ch 7: Analyzing Malicious Windows Programs
 
Investigating Hackers' Tools
Investigating Hackers' ToolsInvestigating Hackers' Tools
Investigating Hackers' Tools
 
Practical Malware Analysis Ch13
Practical Malware Analysis Ch13Practical Malware Analysis Ch13
Practical Malware Analysis Ch13
 
Metasploit & Windows Kernel Exploitation
Metasploit & Windows Kernel ExploitationMetasploit & Windows Kernel Exploitation
Metasploit & Windows Kernel Exploitation
 
Injection on Steroids: Codeless code injection and 0-day techniques
Injection on Steroids: Codeless code injection and 0-day techniquesInjection on Steroids: Codeless code injection and 0-day techniques
Injection on Steroids: Codeless code injection and 0-day techniques
 
CNIT 126 12: Covert Malware Launching
CNIT 126 12: Covert Malware LaunchingCNIT 126 12: Covert Malware Launching
CNIT 126 12: Covert Malware Launching
 
IDA Vulnerabilities and Bug Bounty  by Masaaki Chida
IDA Vulnerabilities and Bug Bounty  by Masaaki ChidaIDA Vulnerabilities and Bug Bounty  by Masaaki Chida
IDA Vulnerabilities and Bug Bounty  by Masaaki Chida
 
Practical Malware Analysis: Ch 8: Debugging
Practical Malware Analysis: Ch 8: Debugging Practical Malware Analysis: Ch 8: Debugging
Practical Malware Analysis: Ch 8: Debugging
 
Process injection - Malware style
Process injection - Malware styleProcess injection - Malware style
Process injection - Malware style
 

Viewers also liked

Final Project Report Nadar
Final Project Report NadarFinal Project Report Nadar
Final Project Report NadarMaher Nadar
 
Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Rhydham Joshi
 
Windows Memory Forensic Analysis using EnCase
Windows Memory Forensic Analysis using EnCaseWindows Memory Forensic Analysis using EnCase
Windows Memory Forensic Analysis using EnCaseTakahiro Haruyama
 
REMnux tutorial 4.1 - Datagrams, Fragmentation & Anomalies
REMnux tutorial 4.1 - Datagrams, Fragmentation & AnomaliesREMnux tutorial 4.1 - Datagrams, Fragmentation & Anomalies
REMnux tutorial 4.1 - Datagrams, Fragmentation & AnomaliesRhydham Joshi
 

Viewers also liked (6)

Malware protection system
Malware protection systemMalware protection system
Malware protection system
 
Final Project Report Nadar
Final Project Report NadarFinal Project Report Nadar
Final Project Report Nadar
 
Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1Anomalies Detection: Windows OS - Part 1
Anomalies Detection: Windows OS - Part 1
 
List of Malwares
List of MalwaresList of Malwares
List of Malwares
 
Windows Memory Forensic Analysis using EnCase
Windows Memory Forensic Analysis using EnCaseWindows Memory Forensic Analysis using EnCase
Windows Memory Forensic Analysis using EnCase
 
REMnux tutorial 4.1 - Datagrams, Fragmentation & Anomalies
REMnux tutorial 4.1 - Datagrams, Fragmentation & AnomaliesREMnux tutorial 4.1 - Datagrams, Fragmentation & Anomalies
REMnux tutorial 4.1 - Datagrams, Fragmentation & Anomalies
 

Similar to Malicious File for Exploiting Forensic Software

Super Easy Memory Forensics
Super Easy Memory ForensicsSuper Easy Memory Forensics
Super Easy Memory ForensicsIIJ
 
Introduction to Android Development and Security
Introduction to Android Development and SecurityIntroduction to Android Development and Security
Introduction to Android Development and SecurityKelwin Yang
 
Selenium for everyone
Selenium for everyoneSelenium for everyone
Selenium for everyoneTft Us
 
IWMW 1999: Browser management
IWMW 1999: Browser managementIWMW 1999: Browser management
IWMW 1999: Browser managementIWMW
 
AD113 Speed Up Your Applications w/ Nginx and PageSpeed
AD113  Speed Up Your Applications w/ Nginx and PageSpeedAD113  Speed Up Your Applications w/ Nginx and PageSpeed
AD113 Speed Up Your Applications w/ Nginx and PageSpeededm00se
 
Creating Havoc using Human Interface Device
Creating Havoc using Human Interface DeviceCreating Havoc using Human Interface Device
Creating Havoc using Human Interface DevicePositive Hack Days
 
Profiling and Tuning a Web Application - The Dirty Details
Profiling and Tuning a Web Application - The Dirty DetailsProfiling and Tuning a Web Application - The Dirty Details
Profiling and Tuning a Web Application - The Dirty DetailsAchievers Tech
 
Metasploitation part-1 (murtuja)
Metasploitation part-1 (murtuja)Metasploitation part-1 (murtuja)
Metasploitation part-1 (murtuja)ClubHack
 
Adding Security and Compliance to Your Workflow with InSpec
Adding Security and Compliance to Your Workflow with InSpecAdding Security and Compliance to Your Workflow with InSpec
Adding Security and Compliance to Your Workflow with InSpecMandi Walls
 
iOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersiOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersRyanISI
 
Modern Reconnaissance Phase on APT - protection layer
Modern Reconnaissance Phase on APT - protection layerModern Reconnaissance Phase on APT - protection layer
Modern Reconnaissance Phase on APT - protection layerShakacon
 
Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Yury Chemerkin
 
Owasp joy of proactive security
Owasp joy of proactive securityOwasp joy of proactive security
Owasp joy of proactive securityScott Behrens
 
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an..."Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...SegInfo
 
The Joy of Proactive Security
The Joy of Proactive SecurityThe Joy of Proactive Security
The Joy of Proactive SecurityAndy Hoernecke
 
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...PranavPatil822557
 

Similar to Malicious File for Exploiting Forensic Software (20)

Case study
Case studyCase study
Case study
 
Super Easy Memory Forensics
Super Easy Memory ForensicsSuper Easy Memory Forensics
Super Easy Memory Forensics
 
Introduction to Android Development and Security
Introduction to Android Development and SecurityIntroduction to Android Development and Security
Introduction to Android Development and Security
 
Fsoss 2010 en
Fsoss 2010 enFsoss 2010 en
Fsoss 2010 en
 
AppSec & OWASP Top 10 Primer
AppSec & OWASP Top 10 PrimerAppSec & OWASP Top 10 Primer
AppSec & OWASP Top 10 Primer
 
Selenium for everyone
Selenium for everyoneSelenium for everyone
Selenium for everyone
 
IWMW 1999: Browser management
IWMW 1999: Browser managementIWMW 1999: Browser management
IWMW 1999: Browser management
 
AD113 Speed Up Your Applications w/ Nginx and PageSpeed
AD113  Speed Up Your Applications w/ Nginx and PageSpeedAD113  Speed Up Your Applications w/ Nginx and PageSpeed
AD113 Speed Up Your Applications w/ Nginx and PageSpeed
 
Creating Havoc using Human Interface Device
Creating Havoc using Human Interface DeviceCreating Havoc using Human Interface Device
Creating Havoc using Human Interface Device
 
Profiling and Tuning a Web Application - The Dirty Details
Profiling and Tuning a Web Application - The Dirty DetailsProfiling and Tuning a Web Application - The Dirty Details
Profiling and Tuning a Web Application - The Dirty Details
 
Metasploitation part-1 (murtuja)
Metasploitation part-1 (murtuja)Metasploitation part-1 (murtuja)
Metasploitation part-1 (murtuja)
 
Adding Security and Compliance to Your Workflow with InSpec
Adding Security and Compliance to Your Workflow with InSpecAdding Security and Compliance to Your Workflow with InSpec
Adding Security and Compliance to Your Workflow with InSpec
 
iOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersiOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for Beginners
 
Enterprise PHP
Enterprise PHPEnterprise PHP
Enterprise PHP
 
Modern Reconnaissance Phase on APT - protection layer
Modern Reconnaissance Phase on APT - protection layerModern Reconnaissance Phase on APT - protection layer
Modern Reconnaissance Phase on APT - protection layer
 
Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...
 
Owasp joy of proactive security
Owasp joy of proactive securityOwasp joy of proactive security
Owasp joy of proactive security
 
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an..."Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...
"Automated Malware Analysis" de Gabriel Negreira Barbosa, Malware Research an...
 
The Joy of Proactive Security
The Joy of Proactive SecurityThe Joy of Proactive Security
The Joy of Proactive Security
 
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...
Machine Learning , Analytics & Cyber Security the Next Level Threat Analytics...
 

Recently uploaded

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 

Recently uploaded (20)

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 

Malicious File for Exploiting Forensic Software

  • 1. Malicious File for Exploiting Forensic Software Takahiro Haruyama / Hiroshi Suzuki Internet Initiative Japan Inc.
  • 2. • Forensic Investigator & Malware Analyst @ Internet Initiative Japan • Presentations – SANS DFIR Summit, Blackhat EU, RSA Conference Japan, etc.. • Hands-ons – CEIC, FIRST TC Kyoto/Lisbon, etc.. • Tools – EnCase EnScript, IDAPython script, etc.. – http://cci.cocolog-nifty.com/blog/ • EnCase Certified Examiner since 2009 • twitter: @cci_forensics Who am I?
  • 3. • Background • Fuzzing Oracle Outside In • Anti-forensics by exploiting bugs • Countermeasures • Wrap-up Overview
  • 5. • Forensic software needs a function viewing file content – Most commercial tools adopt the same library • e.g., EnCase, FTK, X-Ways, etc.. • Oracle Outside In Technology [1] – analyze/extract/convert over 500 different file types data – also used by enterprise software • e.g., Microsoft Exchange, Cisco Security Agent, IBM OmniFind Enterprise Edition, McAfee GroupShield, Symantec Enterprise Vault File Viewer in Forensic Software
  • 6. • Several bugs of Oracle Outside In were reported last year [2] • If still exploitable, lots of forensic investigators are exposed to risks when viewing/processing crafted malicious files – process hang-up – other anti-forensic techniques • e.g., data alternation or hiding, evidence deletion – malware infection with privilege • e.g., owning forensic workstations for government organizations  • Researched about the exploitability Motivation
  • 8. • The fuzzer using EnCase – MiniFuzz [3] – EnCase EnScript – kernel driver Fuzzer Implementation EnCase EnCase EnScript MiniFuzz Kernel Driver mutate files & run EnCase prevent detection call Outside In function
  • 9. • EnScript methods calling Outside In – DocumentClass • GetDocView – Returns a list containing one image for each page in the document • WriteTranscript – Returns a text extracted from the document • One pitfall – EnScript can’t receive command-line arguments • Use 3rd party tool [4] EnScript for Fuzzer
  • 12. • Two examples – Process hang-up using infinite loop DoS vulnerability – Arbitrary code execution using heap overflow vulnerability • Tested Outside In versions (latest: 8.4.1) – 8.3.5 on EnCase 6 • To tell the truth, most EnCase users prefer 6 to 7  – 8.3.7 on X-Ways Forensics • X-Ways recommends 8.3.7 instead of 8.4.1 for web history examination – 8.4.0 on EnCase 7 Anti-forensics by exploiting bugs
  • 13. • Included in the function parsing Hangul Word Processor format document – A malicious file can cause infinite loop in vshwp2.dll • JVN#68663052 [5] (CVE-2013-3776 [6]) – Affected version: 8.4.1 and earlier – Resolved on July 16th, 2013 [7] Process Hang-up using Infinite Loop DoS Vulnerability
  • 14. • 8.4.0 on EnCase 7 Demo
  • 15. • Included in the function parsing Ichitaro format document – A malicious file can overwrite heap chunks • JVN#07497769 [8] (CVE-2013-3781 [9]) – Affected version: 8.3.7 and earlier – Resolved on July 16th, 2013 [7] Arbitrary Code Execution using Heap Overflow Vulnerability
  • 16. • Vista or later Windows OS adopt various mitigation techniques to prevent an exploitation of heap overflow [10] – Look-aside lists have been replaced by the Low Fragmentation Heap (LFH) – heap entry metadata randomization – randomized heap base address – etc... • One promising method is overwriting function pointers in heap chunks – But the offset values to them are not constant Overwriting Function Pointers
  • 17. • Heap spraying is a payload delivery technique – It allows us to put our shellcodes at a predictable address (e.g., 0x0c0c0c0c) • We need to fill chunks of memory in the heap before gaining control over EIP • How? – Javascript or vbscript in web browsers – Javascript or ActionScript in Adobe Reader – ? in forensic software Heap Spraying
  • 18. • Bitmap heap spraying [11] is an effective technique because forensic investigators often examine image files • Most forensic software supports displaying several images at the same time – EnCase • “Bookmark Page as Image” in Doc view • Make the bookmarked images “set-included” – X-Ways Forensics • Double-click image files Heap Spraying with Bitmap Images
  • 19. Heap Spraying with Bitmap Images: Example on EnCase 6
  • 20. • 8.3.5 on EnCase 6 • 8.3.7 on X-Ways Forensics Demo
  • 21. • Not necessarily succeed – Function pointers called in a short time should be included in overwritten area • e.g., sccch/sccut/sccvw, ole32, etc.. – current success probability • EnCase 6 – 40-50% • X-Ways – 10-20% – To improve the probability, we need to manipulate heap chunk layout before causing overflow  Success Probability of the Heap Overflow Exploitation
  • 23. • Developers should – check buffer boundary to prevent overflow – enable “HeapEnableTerminateOnCorruption“ • Use HeapSetInformation [12] API • If a heap corruption detected, the process terminates immediately – 0xc0000374 (STATUS_HEAP_CORRUPTION) Prevention of Arbitrary Code Execution using Heap Overflow
  • 24. • Disable the operation for bitmap heap spray – EnCase 6 • [Tools] -> [Options] -> [Global] • uncheck “Enable Pictures in Doc View” – X-Ways Forensics • [Options] -> [Viewer Programs] • uncheck “For pictures, too” Heap spray Prevention
  • 25. • Use the latest version – 8.4.0 or later seems to fix most bugs discovered by my fuzzer • Do not use EnCase 6 / X-Ways with 8.3.7 • Do not install file viewer – We can install EnCase/X-Ways without Outside In • Configure for using native applications (e.g., Microsoft Word for doc/docx files) • Configure for exploit mitigation [13] – e.g., EMET, AppLocker, etc... Common Countermeasures
  • 27. • Know the risk when examining unknown files acquired in forensic investigation – The file viewer component is fragile • Several bugs still remain in the old version (e.g., .doc) – Investigators should pay attention to the security settings of their workstations • Forensic software vendors tend to use an old version of the component – They should update their products as soon as the latest version of Outside In is released – Much the same is true on enterprise software Wrap-up
  • 28. 28 Questions? (twitter: @cci_forensics) Please scan your badges for evaluation surveys!
  • 29. [1] Oracle Outside In Technology <http://www.oracle.com/us/technologies/embedded/025613.htm> [2] Oracle Outside In contains multiple exploitable vulnerabilities <https://www.kb.cert.org/vuls/id/118913> [3] SDL MiniFuzz File Fuzzer <http://www.microsoft.com/en-us/download/details.aspx?id=21769> [4] Command Line DLL.zip <http://www.swiftforensics.com/p/downloads.html> [5] JVN#68663052 Oracle Outside In vulnerable to denial-of-service (DoS) <http://jvn.jp/en/jp/JVN68663052/index.html> [6] CVE-2013-3776 <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-3776> [7] Oracle Critical Patch Update Advisory - July 2013 <http://www.oracle.com/technetwork/topics/security/cpujuly2013-1899826.html> [8] JVN#07497769 Oracle Outside In vulnerable to buffer overflow <http://jvn.jp/en/jp/JVN07497769/index.html> [9] CVE-2013-3781 <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2013-3781> [10] Preventing the exploitation of user mode heap corruption vulnerabilities <http://blogs.technet.com/b/srd/archive/2009/08/04/preventing-the-exploitation-of-user- mode-heap-corruption-vulnerabilities.aspx> [11] Exploit writing tutorial part 11 : Heap spraying Demystified <https://www.corelan.be/index.php/2011/12/31/exploit-writing-tutorial-part-11-heap- spraying-demystified/> [12] HeapSetInformation function <http://msdn.microsoft.com/en-us/library/windows/desktop/aa366705(v=vs.85).aspx> [13] Forensics Software and Oracle Outside In <https://www.cert.org/blogs/certcc/2013/07/forensics_software_and_oracle.html> 29 References