SlideShare a Scribd company logo
1 of 55
Download to read offline
AutomatingAnalysis and Exploitation of
Embedded Device Firmware
By: Malachi Jones, PhD
About Me
 Education
 Bachelors Degree: Computer Engineering (Univ. of Florida, 2007)
 Master’s Degree: Computer Engineering (GeorgiaTech, 2009)
 PhD: Computer Engineering (GeorgiaTech, 2013)
 Cyber Security Experience
 Harris: Cyber Software Engineer (2013-2014)
 Harris: Vulnerability Researcher (2015)
 BoozAllen Dark Labs: Embedded Security Researcher (2016- Present)
https://www.linkedin.com/in/malachijonesphd
About Dark Labs
BoozAllen Dark Labs is an elite team of security researchers,
penetration testers, reverse engineers, network
analysts, and data scientists, dedicated to stopping
cyber attacks before they occur.1
(1 http://darklabs.bah.com)
Outline
 Motivation
 Background
 Firmware Analysis
 Automated Exploit Generation
 Intermediate Representation (IR) Languages
 LLVM
 Architecture Independent Analysis and Exploitation
 Conclusion
Motivation
 Embedded in Society
Critical Infrastructure
(Nuclear Power Plant)
Life Critical Systems
(Pace Maker)
Financial Infrastructure
(Banking & Investing)
Internet ofThings (IoT)
(IoT Gadgets)
Commercial Products
(Network Switch)
Transportation Systems
(Jeep)
Motivation
 Workhorses Behind the Embedded Scene
Hexagon MSP 430 SuperH
MIPS ARM PowerPC
Motivation
Why is embedded device security difficult? (vs. gen. purpose computing)
1. Multi Architecture Support:
 Plethora of architectures that are utilized in embedded devices versus
ubiquitous adoption of x86 & x86_64 for general purpose computing
 This often requires security tool development for each architecture
Motivation
Why is embedded device security difficult? (vs. gen. purpose computing)
2. Custom Hardware:
 Embedded devices utilize custom and/or esoteric hardware (e.g. sensors) to
perform specialized tasks
 Difficult to emulate custom hardware, which is often required to achieve
scale for dynamic analysis
Motivation
Why is embedded device security difficult? (vs. gen. purpose computing)
3. Environmental Constraints:
 Depending on where the device is deployed, it may be constrained by mass, power,
cost, or volume that can also impact performance and memory
 Mainstream features on general purpose devices such as ASLR or DEP may be
sacrificed to satisfy environmental and/or computational constraints
Motivation
Why is embedded device security difficult? (vs. gen. purpose computing)
4. Security as an Afterthought:
 Often financially and/or technically infeasible to retrofit security capabilities to
an embedded system that was not originally designed for it
 Once deployed to target environment, embedded devices may be in operation
for 10+ years. Because of (3), Moore's Law does not apply
Objectives ofTalk
 Discussion of an approach for addressing the challenge of building
analysis tools that can support multiple embedded architectures
 Specifically, we’ll explore an approach for decoupling architecture
specifics from the analysis by utilizing llvm, a widely supported
intermediate representation (IR) language
Background
Firmware Analysis
Background: FirmwareAnalysis
 Static Firmware Analysis:
 Analysis of computer software that is performed without the actual execution
of the software code
 Data Flow analysis is a type of static analysis that can be used to understand
and evaluate how “data flows” through the code paths of the program
 Taint analysis is a specific application of data flow analysis that follows user
controlled data to identify code paths that process that data
Background: FirmwareAnalysis
 Taint Analysis
 Can be very instrumental in identifying user-controlled vulnerable code
 General Process
 Step 1: Identify source data inputs that originate from user
 Step 2: Follow the code paths that process (e.g. transformations and reads) the
user data inputs
 Step 3: Keep track of code that reads the user data
 A simple example to illustrate the concept of taint analysis can bee seen on
the following slide
v
Taint Analysis Example
15
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
v
Step 1: Identify Originating User Controlled Input
16
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
User controlled input
(via command line)
v
Step 2: Follow Code that Processes Data
17
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
‘values’ holds a
reference to user
controlled data
v
Step 2: Follow Code that Processes Data
18
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
Call to method that
indirectly uses user
controlled data
v
Step 2: Follow Code that Processes Data
19
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
Alias of
values, which
is user
controlled
v
Step 2: Follow Code that Processes Data
20
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
‘strlen’
function reads
value
v
Step 3: Identify read operations
21
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
Read operation
performed on user
controlled data
Background: FirmwareAnalysis
 Dynamic Firmware Analysis:
 Execution of software in an instrumented or monitored manner to garner
more concrete information on behavior
 Typically, software is executed in an instrumented emulator (e.g. QEMU) as
the emulator offers fine grained execution control
 Emulators also provide the ability to parallelize the analysis without the need
of additional physical devices
Background: FirmwareAnalysis
 Complications of DynamicAnalysis in Embedded Systems
 Dynamic analysis is most effective via an emulator, but emulation of
embedded devices can be non-trivial
 Embedded devices often use many variations of esoteric hardware that have
little to no documentation, which makes emulating hardware problematic
 The emulators may have limited support for the firmware’s processor
architecture or the particular version of the processor
Background: FirmwareAnalysis
 Approaches to address emulation problem (Not exhaustive)
 Manual Static Analysis of Native Binary
 Popular approach that can require a significant amount of manual human analysis
 Much manual effort spent identifying & filtering out false-positives
 Event Driven Dynamic Analysis Framework: (Avatar) [1]
 Firmware code is executed inside an emulator.
 Any I/O access is then intercepted and forwarded to the physical device
 Firmware Adaption [2]
 Extracting limited parts of firmware code to emulate it in a generic emulator
 The focus is typically on user code that does not require significant I/O access or
system calls
Background: FirmwareAnalysis
 Static vs. Dynamic Analysis
 Static analysis scales well and can provide better code coverage
 Dynamic analysis can uncover more “actual” vulnerabilities because only
code paths that generate unexpected behavior during execution are analyzed
 A potential code path marked as vulnerable during static analysis may not be
reachable during actual execution
 Static analysis requires that you know the type of vulnerability that you want
to look for (e.g. buffer overflow and integer underflow)
Background
Automated Exploit Generation
Background: Automated Exploit Generation
 Automated Exploit Generation (AEG)
 Given a program, automatically find vulnerabilities and
generate exploits for them.
 One of the core objectives in DARPA’s Cyber Grand Challenge
Background: Automated Exploit Generation
 Steps for AEG [3]
1. Bug-finding: Perform dynamic binary analysis to discover unsafe execution
states
2. Exploit Generation: For a specified unsafe execution state, generate a
candidate exploit input (e.g. return-to-stack and return-to-libc)
3. Verification: Feed in the exploit input into program to verify that control flow
was altered in a desirable manner (e.g. spawn a shell)
Background: Automated Exploit Generation
 Commonly used bug-finding techniques for AEG
 Fuzzing: Generate random permutations of a given input and monitor the
program for crashes.
 Symbolic Execution: Analysis of a program to determine the necessary
inputs needed to reach a particular code path.Variables modeled as symbols
 Concolic Execution: Used in conjunction with symbolic execution to generate
concrete inputs (test cases) from symbolic variables to feed into program
 Selective Symbolic Execution*: Fuzzing + Selective Concolic Execution
* Approach used by the CGC teams that include Shellphish [4]
Background: Automated Exploit Generation
 Example: Symbolic Execution
Example taken from the following publication: SymbolicCrosschecking of Data-Parallel Floating-Point Code (2014)
Background: Automated Exploit Generation
 Complications with AEG (not exhaustive)
 Not all bugs are exploitable (e.g. may not be able to alter control flow in a
desirable manner)
 Not all exploits are reliable (e.g. exploit requires an unlikely execution state)
 Discovering the exploitable path among an infinite number of feasible paths
is non-trivial
 Requires dynamic analysis, which is also non-trivial for embedded systems
Background
Intermediate Representation (IR) Languages
Background: IR Languages
 Formal Definition:The language of an abstract machine designed to aid
in the analysis of computer programs2
 IR Languages (Not Exhaustive):
1. Java Byte Code
2. Microsoft’s Common Intermediate Language (shared by .NET Framework compilers)
3. ESIL3 ( radare2 disassembler)
4. BAP [5] (Binary Analysis Platform)
5. REIL [6] (Static CodeAnalysis)
6. SWIFT4
7. LLVM [7] ( Compiler Optimization)
(2 https://en.wikipedia.org/wiki/Intermediate_representation)
(3 https://radare.gitbooks.io/radare2book/content/esil.html)
(4 https://github.com/apple/swift/blob/master/docs/SIL.rst)
Background: IR Languages
 IR Utilization in Disassemblers
 An approach that disassemblers (e.g. IDA Pro, Binary Ninja, and radare2) utilize is to
convert the binaries to IR for control flow and data flow analysis
 For example, radare2 supports the following architectures4: 6502, 8051, CRIS, H8/300,
LH5801,T8200, arc, arm, avr, bf, blackfin, xap, dalvik, dcpu16, gameboy, i386, i4004, i8080, m68k,
malbolge, mips, msil, msp430, nios II, powerpc, rar, sh, snes, sparc, tms320 (c54x c55x c55+),V810,
x86-64, zimg, risc-v.
 Instead of creating an analysis tool for each architecture, radare2 performs analysis on its custom
IR, ESIL (Evaluable Strings Intermediate Language)
 Example x86 to ESIL Translation:
(4 https://github.com/radare/radare2)
mov eax, [0x80480] 0x80480,[],eax,=, #8
LLVM
LLVM
 LLVM is a common infrastructure to implement a broad variety of
compiled languages that include5
 The family of languages supported by GCC (e.g. C, and C++)
 Java
 .NET
 Python (via Cpython)
( 5 http://www.aosabook.org/en/llvm.html)
LLVM
(5)
LLVM
 Typical use case
1. Translate programming language (e.g. C) to llvm IR (Front end)
2. Perform compiler optimizations on llvm IR (Optimization)
3. Translate llvm to target machine language, e.g. x86 (Back end)
( 6 http://www.aosabook.org/en/llvm.html)
LLVM
(6)
LLVM
 Example “hello world” llvm IR7
(7 http://llvm.org/docs/LangRef.html)
subs R2, R2, #8
v
; Declare the string constant as a global constant.
@.str = private unnamed_addr constant [13 x i8] c"hello world0A00"
; External declaration of the puts function
declare i32 @puts(i8* nocapture) nounwind
; Definition of main function
define i32 @main() { ; i32()*
; Convert [13 x i8]* to i8 *...
%cast210 = getelementptr [13 x i8], [13 x i8]* @.str, i64 0, i64 0
; Call puts function to write out the string to stdout.
call i32 @puts(i8* %cast210)
ret i32 0
}
; Named metadata
!0 = !{i32 42, null, !"string"}
!foo = !{!0}
LLVM
 Supported back end targets include
 x86 & x86_64
 ARM
 MIPS
 PowerPC
 Hexagon
 Back end code is typically maintained by the processor’s
designers (e.g. Intel maintains the x86 & x86_64 llvm back end)
LLVM
 Analysis Libraries
 One of the core functions of LLVM is to perform optimizations (e.g. eliminate dead
code and redundant stores) on its IR to produce efficient code
 It uses a powerful set of libraries written in C++ to analyze the code to identify
optimizations
 These libraries can also be used for static analysis to find potential vulnerabilities
 Example: We can perform loop analysis on any llvm instruction to determine the
following
 If the instruction is in a loop
 What are the exit conditions for the loop (e.g. i<10)
 Could be useful in identifying buffer overflows
Architecture Independent Analysis and Exploitation
Architecture Independent Analysis and Exploitation
 So how can we utilize LLVM to analyze & exploit firmware?
 Build a tool that can perform automated static analysis on the IR to find potential bugs
 In particular, we can exploit the fact that static analysis can provide us with more
comprehensive code coverage
 Bugs that we may be interested in identifying include use-after-free, buffer overflow,
and buffer underflow
?llvm ir
Architecture Independent Analysis and Exploitation
 StaticAnalysis Example
 Suppose we have a binary ‘simpleArray’ that has a potential buffer overflow
vulnerability in one of its functions
 The vulnerable code in its C representation can be seen on the next slide
llvm ir
v
simpleArray.c
44
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
Architecture IndependentAnalysis and Exploitation
 Snippet of llvm ir (Static Analysis Example)
v
define i32 @initializeArray(i32* %someArray, i8* %initializingValues) #0 {
%1 = alloca i32*, align 8
%2 = alloca i8*, align 8
%length = alloca i32, align 4
%i = alloca i32, align 4
store i32* %someArray, i32** %1, align 8
store i8* %initializingValues, i8** %2, align 8
%3 = load i8** %2, align 8
%4 = call i64 @strlen(i8* %3) #3
%5 = trunc i64 %4 to i32
store i32 %5, i32* %length, align 4
store i32 0, i32* %i, align 4
br label %6
………………………………
; <label>:31 ; preds = %6
ret i32 0
}
Architecture Independent Analysis and Exploitation
 StaticAnalysis Example
 Objective is to identify buffer overflows that occur on fixed size arrays
 Next few slides will demonstrate how we can use our tool to accomplish this
llvm ir
Buffer Overflow Detection Example
Buffer Overflow Detection Example
v
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
User controls
operand `length’
of exit condition
User Controlled operand
of exit condition
Buffer Overflow Detection Example
Out of bounds write
detected (myArray)
v
SimpleArray.c
50
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int initializeArray(int * someArray, char * initiValues);
int main(int argc, char *argv[]){
int myArray [10];
if(argc != 2)
{
printf("usage:Expected 2 arguments... Received:%dn",argc);
return 1;
}
char * values = argv[1];
initializeArray(myArray, values);
return 0;
}
int initializeArray(int * someArray, char *initializingValues){
int length = strlen(initializingValues);
for( int i =0; i <length; i++) {
someArray[i] = (int) initializingValues[i] ;
printf("someArray[%d] = %dn",i, someArray[i]);
}
return 0;
}
Buffer overflow
occurs if user
passes in a string
with length > 10
Overflowed buffer
Architecture Independent Analysis and Exploitation
 Open Source AnalysisTool (Klee)
 Klee is a popular analysis tool that takes as input llvm bitcode
 Applied to all 90 programs in the GNU COREUTILS utility suite, which forms
the core user-level environment installed on most Unix systems [9]
 When program execution branches based on a symbolic value, klee follows
both branches at once, maintaining on each path a set of constraints called
the path condition
 When a path terminates or hits a bug, a test case can be generated by using
the current path condition to find concrete values that can generate the bug
• Automated vulnerability analysis tools have the potential to allow the larger embedded
community to conduct effective analysis, at scale, that has historically been limited to a
small group of security experts
• However, there are some challenges (e.g. hardware emulation and multi-architecture
support ) that will need to addressed before the potential can be realized
• In this talk, we’ve discussed an approach to address the multi-architecture support
challenge by utilizing LLVM IR
Conclusion
References
1. Ruffell, Matthew, et al. "Towards Automated Exploit Generation for Embedded Systems."
2. Zaddach, Jonas, et al. "AVATAR: A Framework to Support Dynamic Security Analysis of
Embedded Systems' Firmwares." NDSS. 2014.
3. Avgerinos, Thanassis, et al. "Automatic exploit generation." Communications of the ACM 57.2
(2014): 74-84.
4. Stephens, Nick, et al. "Driller: Augmenting Fuzzing Through Selective Symbolic Execution."
Proceedings of the Network and Distributed System Security Symposium. 2016.
5. Brumley, David, et al. "BAP: A binary analysis platform." International Conference on
Computer Aided Verification. Springer Berlin Heidelberg, 2011
6. Dullien,Thomas, and Sebastian Porst. "REIL: A platform-independent intermediate
representation of disassembled code for static code analysis." Proceeding of CanSecWest
(2009).
7. Lattner, Chris, andVikram Adve. "LLVM: A compilation framework for lifelong program
analysis & transformation." Code Generation and Optimization, 2004. CGO 2004.
International Symposium on. IEEE, 2004.
References
8. Lopes, Bruno Cardoso, and Rafael Auler. Getting Started with LLVM Core Libraries. Packt
Publishing Ltd, 2014.
9. Cadar, Cristian, Daniel Dunbar, and Dawson R. Engler. "KLEE: Unassisted and Automatic
Generation of High-CoverageTests for Complex Systems Programs." OSDI.Vol. 8. 2008.
10. Anderson, Ross. "Why information security is hard-an economic perspective." Computer
security applications conference, 2001. acsac 2001. proceedings 17th annual. IEEE, 2001.
Questions?
 Contact Information
 Email: jones_malachi@bah.com
 LinkedIn: https://www.linkedin.com/in/malachijonesphd

More Related Content

What's hot

Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareUsing Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareLastline, Inc.
 
The Finest Penetration Testing Framework for Software-Defined Networks
The Finest Penetration Testing Framework for Software-Defined NetworksThe Finest Penetration Testing Framework for Software-Defined Networks
The Finest Penetration Testing Framework for Software-Defined NetworksPriyanka Aash
 
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...Priyanka Aash
 
Network Security Data Visualization
Network Security Data VisualizationNetwork Security Data Visualization
Network Security Data Visualizationamiable_indian
 
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...Lastline, Inc.
 
AI & ML in Cyber Security - Why Algorithms are Dangerous
AI & ML in Cyber Security - Why Algorithms are DangerousAI & ML in Cyber Security - Why Algorithms are Dangerous
AI & ML in Cyber Security - Why Algorithms are DangerousRaffael Marty
 
Why is it so hard to make secure chips?
Why is it so hard to make secure chips?Why is it so hard to make secure chips?
Why is it so hard to make secure chips?Riscure
 
Detecting Evasive Malware in Sandbox
Detecting Evasive Malware in SandboxDetecting Evasive Malware in Sandbox
Detecting Evasive Malware in SandboxRahul Mohandas
 
Ethical Hacking &amp; Penetration Testing
Ethical  Hacking &amp;  Penetration  TestingEthical  Hacking &amp;  Penetration  Testing
Ethical Hacking &amp; Penetration TestingWon Ju Jub
 
RIoT (Raiding Internet of Things) by Jacob Holcomb
RIoT  (Raiding Internet of Things)  by Jacob HolcombRIoT  (Raiding Internet of Things)  by Jacob Holcomb
RIoT (Raiding Internet of Things) by Jacob HolcombPriyanka Aash
 
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017FRSecure
 
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...BlueHat Security Conference
 
Understand How Machine Learning Defends Against Zero-Day Threats
Understand How Machine Learning Defends Against Zero-Day ThreatsUnderstand How Machine Learning Defends Against Zero-Day Threats
Understand How Machine Learning Defends Against Zero-Day ThreatsRahul Mohandas
 
AI for Cybersecurity Innovation
AI for Cybersecurity InnovationAI for Cybersecurity Innovation
AI for Cybersecurity InnovationPete Burnap
 
Slide Deck CISSP Class Session 6
Slide Deck CISSP Class Session 6Slide Deck CISSP Class Session 6
Slide Deck CISSP Class Session 6FRSecure
 
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)Dynamic Population Discovery for Lateral Movement (Using Machine Learning)
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)Rod Soto
 
Revealing the Attack Operations Targeting Japan by Shusei Tomonaga & Yuu Nak...
Revealing the Attack Operations Targeting Japan by  Shusei Tomonaga & Yuu Nak...Revealing the Attack Operations Targeting Japan by  Shusei Tomonaga & Yuu Nak...
Revealing the Attack Operations Targeting Japan by Shusei Tomonaga & Yuu Nak...CODE BLUE
 
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017FRSecure
 

What's hot (20)

Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareUsing Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
 
The Finest Penetration Testing Framework for Software-Defined Networks
The Finest Penetration Testing Framework for Software-Defined NetworksThe Finest Penetration Testing Framework for Software-Defined Networks
The Finest Penetration Testing Framework for Software-Defined Networks
 
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...
From Thousands of Hours to a Couple of Minutes: Automating Exploit Generation...
 
Network Security Data Visualization
Network Security Data VisualizationNetwork Security Data Visualization
Network Security Data Visualization
 
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...
Full-System Emulation Achieving Successful Automated Dynamic Analysis of Evas...
 
AI & ML in Cyber Security - Why Algorithms are Dangerous
AI & ML in Cyber Security - Why Algorithms are DangerousAI & ML in Cyber Security - Why Algorithms are Dangerous
AI & ML in Cyber Security - Why Algorithms are Dangerous
 
Why is it so hard to make secure chips?
Why is it so hard to make secure chips?Why is it so hard to make secure chips?
Why is it so hard to make secure chips?
 
Detecting Evasive Malware in Sandbox
Detecting Evasive Malware in SandboxDetecting Evasive Malware in Sandbox
Detecting Evasive Malware in Sandbox
 
Ethical Hacking &amp; Penetration Testing
Ethical  Hacking &amp;  Penetration  TestingEthical  Hacking &amp;  Penetration  Testing
Ethical Hacking &amp; Penetration Testing
 
Super1
Super1Super1
Super1
 
RIoT (Raiding Internet of Things) by Jacob Holcomb
RIoT  (Raiding Internet of Things)  by Jacob HolcombRIoT  (Raiding Internet of Things)  by Jacob Holcomb
RIoT (Raiding Internet of Things) by Jacob Holcomb
 
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 8 – FRSecure CISSP Mentor Program 2017
 
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...
BlueHat v17 || Extracting Secrets from Silicon – A New Generation of Bug Hunt...
 
Understand How Machine Learning Defends Against Zero-Day Threats
Understand How Machine Learning Defends Against Zero-Day ThreatsUnderstand How Machine Learning Defends Against Zero-Day Threats
Understand How Machine Learning Defends Against Zero-Day Threats
 
AI for Cybersecurity Innovation
AI for Cybersecurity InnovationAI for Cybersecurity Innovation
AI for Cybersecurity Innovation
 
Slide Deck CISSP Class Session 6
Slide Deck CISSP Class Session 6Slide Deck CISSP Class Session 6
Slide Deck CISSP Class Session 6
 
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)Dynamic Population Discovery for Lateral Movement (Using Machine Learning)
Dynamic Population Discovery for Lateral Movement (Using Machine Learning)
 
Revealing the Attack Operations Targeting Japan by Shusei Tomonaga & Yuu Nak...
Revealing the Attack Operations Targeting Japan by  Shusei Tomonaga & Yuu Nak...Revealing the Attack Operations Targeting Japan by  Shusei Tomonaga & Yuu Nak...
Revealing the Attack Operations Targeting Japan by Shusei Tomonaga & Yuu Nak...
 
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017
Slide Deck – Session 11 – FRSecure CISSP Mentor Program 2017
 
A Threat Hunter Himself
A Threat Hunter HimselfA Threat Hunter Himself
A Threat Hunter Himself
 

Viewers also liked

Database mirroring setup
Database mirroring setupDatabase mirroring setup
Database mirroring setupK Singh
 
Xen and the art of embedded virtualization (ELC 2017)
Xen and the art of embedded virtualization (ELC 2017)Xen and the art of embedded virtualization (ELC 2017)
Xen and the art of embedded virtualization (ELC 2017)Stefano Stabellini
 
Creating Great Dashboards - Beyond the Colors & Fonts
Creating Great Dashboards - Beyond the Colors & FontsCreating Great Dashboards - Beyond the Colors & Fonts
Creating Great Dashboards - Beyond the Colors & FontsLogi Analytics
 
Linux Sürücü Geliştirme (Linux Device Driver Development)
Linux Sürücü Geliştirme (Linux Device Driver Development)Linux Sürücü Geliştirme (Linux Device Driver Development)
Linux Sürücü Geliştirme (Linux Device Driver Development)kyasar
 
Introducing the Civil Infrastructure Platform Project
Introducing the Civil Infrastructure Platform ProjectIntroducing the Civil Infrastructure Platform Project
Introducing the Civil Infrastructure Platform ProjectYoshitake Kobayashi
 
Design Of A Usb Device Driver (Overview)
Design Of A Usb Device Driver (Overview)Design Of A Usb Device Driver (Overview)
Design Of A Usb Device Driver (Overview)allankliu
 
An Overview Study on USB OTG Device ISP1761
An Overview Study on USB OTG Device ISP1761An Overview Study on USB OTG Device ISP1761
An Overview Study on USB OTG Device ISP1761Premier Farnell
 
BeagleBone Black Using Python
BeagleBone Black Using PythonBeagleBone Black Using Python
BeagleBone Black Using PythonSai Viswanath
 
Android device driver structure introduction
Android device driver structure introductionAndroid device driver structure introduction
Android device driver structure introductionWilliam Liang
 
Offensive cyber security: Smashing the stack with Python
Offensive cyber security: Smashing the stack with PythonOffensive cyber security: Smashing the stack with Python
Offensive cyber security: Smashing the stack with PythonMalachi Jones
 
Introduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwareIntroduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwaredefinecareer
 
2015 WebConf - Web + Arduino 實在有夠潮
2015 WebConf  - Web + Arduino 實在有夠潮2015 WebConf  - Web + Arduino 實在有夠潮
2015 WebConf - Web + Arduino 實在有夠潮益祥 許
 
The Complete Guide to Embedded Analytics
The Complete Guide to Embedded AnalyticsThe Complete Guide to Embedded Analytics
The Complete Guide to Embedded AnalyticsJessica Sprinkel
 
EMBEDDED WEB SERVER
EMBEDDED WEB SERVEREMBEDDED WEB SERVER
EMBEDDED WEB SERVERkavya Reddy
 
Introduction to char device driver
Introduction to char device driverIntroduction to char device driver
Introduction to char device driverVandana Salve
 
Програмиране на малки микропроцесорни системи
Програмиране на малки микропроцесорни системиПрограмиране на малки микропроцесорни системи
Програмиране на малки микропроцесорни системиNeven Boyanov
 
I2C programming with C and Arduino
I2C programming with C and ArduinoI2C programming with C and Arduino
I2C programming with C and Arduinosato262
 

Viewers also liked (20)

Usb 72213 76207
Usb 72213 76207Usb 72213 76207
Usb 72213 76207
 
Database mirroring setup
Database mirroring setupDatabase mirroring setup
Database mirroring setup
 
Intro
IntroIntro
Intro
 
Xen and the art of embedded virtualization (ELC 2017)
Xen and the art of embedded virtualization (ELC 2017)Xen and the art of embedded virtualization (ELC 2017)
Xen and the art of embedded virtualization (ELC 2017)
 
Creating Great Dashboards - Beyond the Colors & Fonts
Creating Great Dashboards - Beyond the Colors & FontsCreating Great Dashboards - Beyond the Colors & Fonts
Creating Great Dashboards - Beyond the Colors & Fonts
 
Linux Sürücü Geliştirme (Linux Device Driver Development)
Linux Sürücü Geliştirme (Linux Device Driver Development)Linux Sürücü Geliştirme (Linux Device Driver Development)
Linux Sürücü Geliştirme (Linux Device Driver Development)
 
Introducing the Civil Infrastructure Platform Project
Introducing the Civil Infrastructure Platform ProjectIntroducing the Civil Infrastructure Platform Project
Introducing the Civil Infrastructure Platform Project
 
Design Of A Usb Device Driver (Overview)
Design Of A Usb Device Driver (Overview)Design Of A Usb Device Driver (Overview)
Design Of A Usb Device Driver (Overview)
 
An Overview Study on USB OTG Device ISP1761
An Overview Study on USB OTG Device ISP1761An Overview Study on USB OTG Device ISP1761
An Overview Study on USB OTG Device ISP1761
 
BeagleBone Black Using Python
BeagleBone Black Using PythonBeagleBone Black Using Python
BeagleBone Black Using Python
 
Android device driver structure introduction
Android device driver structure introductionAndroid device driver structure introduction
Android device driver structure introduction
 
Offensive cyber security: Smashing the stack with Python
Offensive cyber security: Smashing the stack with PythonOffensive cyber security: Smashing the stack with Python
Offensive cyber security: Smashing the stack with Python
 
Usb Overview
Usb OverviewUsb Overview
Usb Overview
 
Introduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmwareIntroduction to embedded linux device driver and firmware
Introduction to embedded linux device driver and firmware
 
2015 WebConf - Web + Arduino 實在有夠潮
2015 WebConf  - Web + Arduino 實在有夠潮2015 WebConf  - Web + Arduino 實在有夠潮
2015 WebConf - Web + Arduino 實在有夠潮
 
The Complete Guide to Embedded Analytics
The Complete Guide to Embedded AnalyticsThe Complete Guide to Embedded Analytics
The Complete Guide to Embedded Analytics
 
EMBEDDED WEB SERVER
EMBEDDED WEB SERVEREMBEDDED WEB SERVER
EMBEDDED WEB SERVER
 
Introduction to char device driver
Introduction to char device driverIntroduction to char device driver
Introduction to char device driver
 
Програмиране на малки микропроцесорни системи
Програмиране на малки микропроцесорни системиПрограмиране на малки микропроцесорни системи
Програмиране на малки микропроцесорни системи
 
I2C programming with C and Arduino
I2C programming with C and ArduinoI2C programming with C and Arduino
I2C programming with C and Arduino
 

Similar to Automating Analysis and Exploitation of Embedded Device Firmware

How Automated Vulnerability Analysis Discovered Hundreds of Android 0-days
How Automated Vulnerability Analysis Discovered Hundreds of Android 0-daysHow Automated Vulnerability Analysis Discovered Hundreds of Android 0-days
How Automated Vulnerability Analysis Discovered Hundreds of Android 0-daysPriyanka Aash
 
An efficient HIDS using System Call Traces.pptx
An efficient HIDS using System Call Traces.pptxAn efficient HIDS using System Call Traces.pptx
An efficient HIDS using System Call Traces.pptxSandeep Maurya
 
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2securityxploded
 
Cloud Observation and Performance Analysis using Solaris 11 DTrace
Cloud Observation and Performance Analysis using Solaris 11 DTraceCloud Observation and Performance Analysis using Solaris 11 DTrace
Cloud Observation and Performance Analysis using Solaris 11 DTraceOrgad Kimchi
 
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...CODE BLUE
 
Possibility of arbitrary code execution by Step-Oriented Programming
Possibility of arbitrary code execution by Step-Oriented ProgrammingPossibility of arbitrary code execution by Step-Oriented Programming
Possibility of arbitrary code execution by Step-Oriented Programmingkozossakai
 
Integris Security - Hacking With Glue ℠
Integris Security - Hacking With Glue ℠Integris Security - Hacking With Glue ℠
Integris Security - Hacking With Glue ℠Integris Security LLC
 
OORPT Dynamic Analysis
OORPT Dynamic AnalysisOORPT Dynamic Analysis
OORPT Dynamic Analysislienhard
 
Embedded presentation
Embedded presentationEmbedded presentation
Embedded presentationrohancool
 
Application Security
Application SecurityApplication Security
Application Securityflorinc
 
Introduction to synchronous programming langauges
Introduction to synchronous programming langaugesIntroduction to synchronous programming langauges
Introduction to synchronous programming langaugesAkshar Desai
 
Georgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityGeorgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityDefconRussia
 
Advanced malware analysis training session3 botnet analysis part2
Advanced malware analysis training session3 botnet analysis part2Advanced malware analysis training session3 botnet analysis part2
Advanced malware analysis training session3 botnet analysis part2Cysinfo Cyber Security Community
 
Seminar Hacking & Security Analysis
Seminar Hacking & Security AnalysisSeminar Hacking & Security Analysis
Seminar Hacking & Security AnalysisDan H
 
Secure Programming
Secure ProgrammingSecure Programming
Secure Programmingalpha0
 
HackInBo2k16 - Threat Intelligence and Malware Analysis
HackInBo2k16 - Threat Intelligence and Malware AnalysisHackInBo2k16 - Threat Intelligence and Malware Analysis
HackInBo2k16 - Threat Intelligence and Malware AnalysisAntonio Parata
 
Security for automation in Internet of Things by using one time password
Security for automation in Internet of Things by using one time passwordSecurity for automation in Internet of Things by using one time password
Security for automation in Internet of Things by using one time passwordSHASHANK WANKHADE
 

Similar to Automating Analysis and Exploitation of Embedded Device Firmware (20)

How Automated Vulnerability Analysis Discovered Hundreds of Android 0-days
How Automated Vulnerability Analysis Discovered Hundreds of Android 0-daysHow Automated Vulnerability Analysis Discovered Hundreds of Android 0-days
How Automated Vulnerability Analysis Discovered Hundreds of Android 0-days
 
An efficient HIDS using System Call Traces.pptx
An efficient HIDS using System Call Traces.pptxAn efficient HIDS using System Call Traces.pptx
An efficient HIDS using System Call Traces.pptx
 
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2
Advanced Malware Analysis Training Session 3 - Botnet Analysis Part 2
 
Cloud Observation and Performance Analysis using Solaris 11 DTrace
Cloud Observation and Performance Analysis using Solaris 11 DTraceCloud Observation and Performance Analysis using Solaris 11 DTrace
Cloud Observation and Performance Analysis using Solaris 11 DTrace
 
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...
Possibility of arbitrary code execution by Step-Oriented Programming by Hiroa...
 
Possibility of arbitrary code execution by Step-Oriented Programming
Possibility of arbitrary code execution by Step-Oriented ProgrammingPossibility of arbitrary code execution by Step-Oriented Programming
Possibility of arbitrary code execution by Step-Oriented Programming
 
Integris Security - Hacking With Glue ℠
Integris Security - Hacking With Glue ℠Integris Security - Hacking With Glue ℠
Integris Security - Hacking With Glue ℠
 
Coding Security: Code Mania 101
Coding Security: Code Mania 101Coding Security: Code Mania 101
Coding Security: Code Mania 101
 
OORPT Dynamic Analysis
OORPT Dynamic AnalysisOORPT Dynamic Analysis
OORPT Dynamic Analysis
 
Embedded presentation
Embedded presentationEmbedded presentation
Embedded presentation
 
Application Security
Application SecurityApplication Security
Application Security
 
Unit 3
Unit 3 Unit 3
Unit 3
 
Introduction to synchronous programming langauges
Introduction to synchronous programming langaugesIntroduction to synchronous programming langauges
Introduction to synchronous programming langauges
 
Georgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software securityGeorgy Nosenko - An introduction to the use SMT solvers for software security
Georgy Nosenko - An introduction to the use SMT solvers for software security
 
Advanced malware analysis training session3 botnet analysis part2
Advanced malware analysis training session3 botnet analysis part2Advanced malware analysis training session3 botnet analysis part2
Advanced malware analysis training session3 botnet analysis part2
 
Seminar Hacking & Security Analysis
Seminar Hacking & Security AnalysisSeminar Hacking & Security Analysis
Seminar Hacking & Security Analysis
 
Secure Programming
Secure ProgrammingSecure Programming
Secure Programming
 
50120140501013
5012014050101350120140501013
50120140501013
 
HackInBo2k16 - Threat Intelligence and Malware Analysis
HackInBo2k16 - Threat Intelligence and Malware AnalysisHackInBo2k16 - Threat Intelligence and Malware Analysis
HackInBo2k16 - Threat Intelligence and Malware Analysis
 
Security for automation in Internet of Things by using one time password
Security for automation in Internet of Things by using one time passwordSecurity for automation in Internet of Things by using one time password
Security for automation in Internet of Things by using one time password
 

Recently uploaded

Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceanilsa9823
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxbodapatigopi8531
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️anilsa9823
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AIABDERRAOUF MEHENNI
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 

Recently uploaded (20)

Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptx
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 

Automating Analysis and Exploitation of Embedded Device Firmware

  • 1. AutomatingAnalysis and Exploitation of Embedded Device Firmware By: Malachi Jones, PhD
  • 2. About Me  Education  Bachelors Degree: Computer Engineering (Univ. of Florida, 2007)  Master’s Degree: Computer Engineering (GeorgiaTech, 2009)  PhD: Computer Engineering (GeorgiaTech, 2013)  Cyber Security Experience  Harris: Cyber Software Engineer (2013-2014)  Harris: Vulnerability Researcher (2015)  BoozAllen Dark Labs: Embedded Security Researcher (2016- Present) https://www.linkedin.com/in/malachijonesphd
  • 3. About Dark Labs BoozAllen Dark Labs is an elite team of security researchers, penetration testers, reverse engineers, network analysts, and data scientists, dedicated to stopping cyber attacks before they occur.1 (1 http://darklabs.bah.com)
  • 4. Outline  Motivation  Background  Firmware Analysis  Automated Exploit Generation  Intermediate Representation (IR) Languages  LLVM  Architecture Independent Analysis and Exploitation  Conclusion
  • 5. Motivation  Embedded in Society Critical Infrastructure (Nuclear Power Plant) Life Critical Systems (Pace Maker) Financial Infrastructure (Banking & Investing) Internet ofThings (IoT) (IoT Gadgets) Commercial Products (Network Switch) Transportation Systems (Jeep)
  • 6. Motivation  Workhorses Behind the Embedded Scene Hexagon MSP 430 SuperH MIPS ARM PowerPC
  • 7. Motivation Why is embedded device security difficult? (vs. gen. purpose computing) 1. Multi Architecture Support:  Plethora of architectures that are utilized in embedded devices versus ubiquitous adoption of x86 & x86_64 for general purpose computing  This often requires security tool development for each architecture
  • 8. Motivation Why is embedded device security difficult? (vs. gen. purpose computing) 2. Custom Hardware:  Embedded devices utilize custom and/or esoteric hardware (e.g. sensors) to perform specialized tasks  Difficult to emulate custom hardware, which is often required to achieve scale for dynamic analysis
  • 9. Motivation Why is embedded device security difficult? (vs. gen. purpose computing) 3. Environmental Constraints:  Depending on where the device is deployed, it may be constrained by mass, power, cost, or volume that can also impact performance and memory  Mainstream features on general purpose devices such as ASLR or DEP may be sacrificed to satisfy environmental and/or computational constraints
  • 10. Motivation Why is embedded device security difficult? (vs. gen. purpose computing) 4. Security as an Afterthought:  Often financially and/or technically infeasible to retrofit security capabilities to an embedded system that was not originally designed for it  Once deployed to target environment, embedded devices may be in operation for 10+ years. Because of (3), Moore's Law does not apply
  • 11. Objectives ofTalk  Discussion of an approach for addressing the challenge of building analysis tools that can support multiple embedded architectures  Specifically, we’ll explore an approach for decoupling architecture specifics from the analysis by utilizing llvm, a widely supported intermediate representation (IR) language
  • 13. Background: FirmwareAnalysis  Static Firmware Analysis:  Analysis of computer software that is performed without the actual execution of the software code  Data Flow analysis is a type of static analysis that can be used to understand and evaluate how “data flows” through the code paths of the program  Taint analysis is a specific application of data flow analysis that follows user controlled data to identify code paths that process that data
  • 14. Background: FirmwareAnalysis  Taint Analysis  Can be very instrumental in identifying user-controlled vulnerable code  General Process  Step 1: Identify source data inputs that originate from user  Step 2: Follow the code paths that process (e.g. transformations and reads) the user data inputs  Step 3: Keep track of code that reads the user data  A simple example to illustrate the concept of taint analysis can bee seen on the following slide
  • 15. v Taint Analysis Example 15 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; }
  • 16. v Step 1: Identify Originating User Controlled Input 16 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } User controlled input (via command line)
  • 17. v Step 2: Follow Code that Processes Data 17 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } ‘values’ holds a reference to user controlled data
  • 18. v Step 2: Follow Code that Processes Data 18 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } Call to method that indirectly uses user controlled data
  • 19. v Step 2: Follow Code that Processes Data 19 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } Alias of values, which is user controlled
  • 20. v Step 2: Follow Code that Processes Data 20 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } ‘strlen’ function reads value
  • 21. v Step 3: Identify read operations 21 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } Read operation performed on user controlled data
  • 22. Background: FirmwareAnalysis  Dynamic Firmware Analysis:  Execution of software in an instrumented or monitored manner to garner more concrete information on behavior  Typically, software is executed in an instrumented emulator (e.g. QEMU) as the emulator offers fine grained execution control  Emulators also provide the ability to parallelize the analysis without the need of additional physical devices
  • 23. Background: FirmwareAnalysis  Complications of DynamicAnalysis in Embedded Systems  Dynamic analysis is most effective via an emulator, but emulation of embedded devices can be non-trivial  Embedded devices often use many variations of esoteric hardware that have little to no documentation, which makes emulating hardware problematic  The emulators may have limited support for the firmware’s processor architecture or the particular version of the processor
  • 24. Background: FirmwareAnalysis  Approaches to address emulation problem (Not exhaustive)  Manual Static Analysis of Native Binary  Popular approach that can require a significant amount of manual human analysis  Much manual effort spent identifying & filtering out false-positives  Event Driven Dynamic Analysis Framework: (Avatar) [1]  Firmware code is executed inside an emulator.  Any I/O access is then intercepted and forwarded to the physical device  Firmware Adaption [2]  Extracting limited parts of firmware code to emulate it in a generic emulator  The focus is typically on user code that does not require significant I/O access or system calls
  • 25. Background: FirmwareAnalysis  Static vs. Dynamic Analysis  Static analysis scales well and can provide better code coverage  Dynamic analysis can uncover more “actual” vulnerabilities because only code paths that generate unexpected behavior during execution are analyzed  A potential code path marked as vulnerable during static analysis may not be reachable during actual execution  Static analysis requires that you know the type of vulnerability that you want to look for (e.g. buffer overflow and integer underflow)
  • 27. Background: Automated Exploit Generation  Automated Exploit Generation (AEG)  Given a program, automatically find vulnerabilities and generate exploits for them.  One of the core objectives in DARPA’s Cyber Grand Challenge
  • 28. Background: Automated Exploit Generation  Steps for AEG [3] 1. Bug-finding: Perform dynamic binary analysis to discover unsafe execution states 2. Exploit Generation: For a specified unsafe execution state, generate a candidate exploit input (e.g. return-to-stack and return-to-libc) 3. Verification: Feed in the exploit input into program to verify that control flow was altered in a desirable manner (e.g. spawn a shell)
  • 29. Background: Automated Exploit Generation  Commonly used bug-finding techniques for AEG  Fuzzing: Generate random permutations of a given input and monitor the program for crashes.  Symbolic Execution: Analysis of a program to determine the necessary inputs needed to reach a particular code path.Variables modeled as symbols  Concolic Execution: Used in conjunction with symbolic execution to generate concrete inputs (test cases) from symbolic variables to feed into program  Selective Symbolic Execution*: Fuzzing + Selective Concolic Execution * Approach used by the CGC teams that include Shellphish [4]
  • 30. Background: Automated Exploit Generation  Example: Symbolic Execution Example taken from the following publication: SymbolicCrosschecking of Data-Parallel Floating-Point Code (2014)
  • 31. Background: Automated Exploit Generation  Complications with AEG (not exhaustive)  Not all bugs are exploitable (e.g. may not be able to alter control flow in a desirable manner)  Not all exploits are reliable (e.g. exploit requires an unlikely execution state)  Discovering the exploitable path among an infinite number of feasible paths is non-trivial  Requires dynamic analysis, which is also non-trivial for embedded systems
  • 33. Background: IR Languages  Formal Definition:The language of an abstract machine designed to aid in the analysis of computer programs2  IR Languages (Not Exhaustive): 1. Java Byte Code 2. Microsoft’s Common Intermediate Language (shared by .NET Framework compilers) 3. ESIL3 ( radare2 disassembler) 4. BAP [5] (Binary Analysis Platform) 5. REIL [6] (Static CodeAnalysis) 6. SWIFT4 7. LLVM [7] ( Compiler Optimization) (2 https://en.wikipedia.org/wiki/Intermediate_representation) (3 https://radare.gitbooks.io/radare2book/content/esil.html) (4 https://github.com/apple/swift/blob/master/docs/SIL.rst)
  • 34. Background: IR Languages  IR Utilization in Disassemblers  An approach that disassemblers (e.g. IDA Pro, Binary Ninja, and radare2) utilize is to convert the binaries to IR for control flow and data flow analysis  For example, radare2 supports the following architectures4: 6502, 8051, CRIS, H8/300, LH5801,T8200, arc, arm, avr, bf, blackfin, xap, dalvik, dcpu16, gameboy, i386, i4004, i8080, m68k, malbolge, mips, msil, msp430, nios II, powerpc, rar, sh, snes, sparc, tms320 (c54x c55x c55+),V810, x86-64, zimg, risc-v.  Instead of creating an analysis tool for each architecture, radare2 performs analysis on its custom IR, ESIL (Evaluable Strings Intermediate Language)  Example x86 to ESIL Translation: (4 https://github.com/radare/radare2) mov eax, [0x80480] 0x80480,[],eax,=, #8
  • 35. LLVM
  • 36. LLVM  LLVM is a common infrastructure to implement a broad variety of compiled languages that include5  The family of languages supported by GCC (e.g. C, and C++)  Java  .NET  Python (via Cpython) ( 5 http://www.aosabook.org/en/llvm.html) LLVM (5)
  • 37. LLVM  Typical use case 1. Translate programming language (e.g. C) to llvm IR (Front end) 2. Perform compiler optimizations on llvm IR (Optimization) 3. Translate llvm to target machine language, e.g. x86 (Back end) ( 6 http://www.aosabook.org/en/llvm.html) LLVM (6)
  • 38. LLVM  Example “hello world” llvm IR7 (7 http://llvm.org/docs/LangRef.html) subs R2, R2, #8 v ; Declare the string constant as a global constant. @.str = private unnamed_addr constant [13 x i8] c"hello world0A00" ; External declaration of the puts function declare i32 @puts(i8* nocapture) nounwind ; Definition of main function define i32 @main() { ; i32()* ; Convert [13 x i8]* to i8 *... %cast210 = getelementptr [13 x i8], [13 x i8]* @.str, i64 0, i64 0 ; Call puts function to write out the string to stdout. call i32 @puts(i8* %cast210) ret i32 0 } ; Named metadata !0 = !{i32 42, null, !"string"} !foo = !{!0}
  • 39. LLVM  Supported back end targets include  x86 & x86_64  ARM  MIPS  PowerPC  Hexagon  Back end code is typically maintained by the processor’s designers (e.g. Intel maintains the x86 & x86_64 llvm back end)
  • 40. LLVM  Analysis Libraries  One of the core functions of LLVM is to perform optimizations (e.g. eliminate dead code and redundant stores) on its IR to produce efficient code  It uses a powerful set of libraries written in C++ to analyze the code to identify optimizations  These libraries can also be used for static analysis to find potential vulnerabilities  Example: We can perform loop analysis on any llvm instruction to determine the following  If the instruction is in a loop  What are the exit conditions for the loop (e.g. i<10)  Could be useful in identifying buffer overflows
  • 42. Architecture Independent Analysis and Exploitation  So how can we utilize LLVM to analyze & exploit firmware?  Build a tool that can perform automated static analysis on the IR to find potential bugs  In particular, we can exploit the fact that static analysis can provide us with more comprehensive code coverage  Bugs that we may be interested in identifying include use-after-free, buffer overflow, and buffer underflow ?llvm ir
  • 43. Architecture Independent Analysis and Exploitation  StaticAnalysis Example  Suppose we have a binary ‘simpleArray’ that has a potential buffer overflow vulnerability in one of its functions  The vulnerable code in its C representation can be seen on the next slide llvm ir
  • 44. v simpleArray.c 44 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; }
  • 45. Architecture IndependentAnalysis and Exploitation  Snippet of llvm ir (Static Analysis Example) v define i32 @initializeArray(i32* %someArray, i8* %initializingValues) #0 { %1 = alloca i32*, align 8 %2 = alloca i8*, align 8 %length = alloca i32, align 4 %i = alloca i32, align 4 store i32* %someArray, i32** %1, align 8 store i8* %initializingValues, i8** %2, align 8 %3 = load i8** %2, align 8 %4 = call i64 @strlen(i8* %3) #3 %5 = trunc i64 %4 to i32 store i32 %5, i32* %length, align 4 store i32 0, i32* %i, align 4 br label %6 ……………………………… ; <label>:31 ; preds = %6 ret i32 0 }
  • 46. Architecture Independent Analysis and Exploitation  StaticAnalysis Example  Objective is to identify buffer overflows that occur on fixed size arrays  Next few slides will demonstrate how we can use our tool to accomplish this llvm ir
  • 48. Buffer Overflow Detection Example v int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } User controls operand `length’ of exit condition User Controlled operand of exit condition
  • 49. Buffer Overflow Detection Example Out of bounds write detected (myArray)
  • 50. v SimpleArray.c 50 #include <stdio.h> #include <stdlib.h> #include <string.h> int initializeArray(int * someArray, char * initiValues); int main(int argc, char *argv[]){ int myArray [10]; if(argc != 2) { printf("usage:Expected 2 arguments... Received:%dn",argc); return 1; } char * values = argv[1]; initializeArray(myArray, values); return 0; } int initializeArray(int * someArray, char *initializingValues){ int length = strlen(initializingValues); for( int i =0; i <length; i++) { someArray[i] = (int) initializingValues[i] ; printf("someArray[%d] = %dn",i, someArray[i]); } return 0; } Buffer overflow occurs if user passes in a string with length > 10 Overflowed buffer
  • 51. Architecture Independent Analysis and Exploitation  Open Source AnalysisTool (Klee)  Klee is a popular analysis tool that takes as input llvm bitcode  Applied to all 90 programs in the GNU COREUTILS utility suite, which forms the core user-level environment installed on most Unix systems [9]  When program execution branches based on a symbolic value, klee follows both branches at once, maintaining on each path a set of constraints called the path condition  When a path terminates or hits a bug, a test case can be generated by using the current path condition to find concrete values that can generate the bug
  • 52. • Automated vulnerability analysis tools have the potential to allow the larger embedded community to conduct effective analysis, at scale, that has historically been limited to a small group of security experts • However, there are some challenges (e.g. hardware emulation and multi-architecture support ) that will need to addressed before the potential can be realized • In this talk, we’ve discussed an approach to address the multi-architecture support challenge by utilizing LLVM IR Conclusion
  • 53. References 1. Ruffell, Matthew, et al. "Towards Automated Exploit Generation for Embedded Systems." 2. Zaddach, Jonas, et al. "AVATAR: A Framework to Support Dynamic Security Analysis of Embedded Systems' Firmwares." NDSS. 2014. 3. Avgerinos, Thanassis, et al. "Automatic exploit generation." Communications of the ACM 57.2 (2014): 74-84. 4. Stephens, Nick, et al. "Driller: Augmenting Fuzzing Through Selective Symbolic Execution." Proceedings of the Network and Distributed System Security Symposium. 2016. 5. Brumley, David, et al. "BAP: A binary analysis platform." International Conference on Computer Aided Verification. Springer Berlin Heidelberg, 2011 6. Dullien,Thomas, and Sebastian Porst. "REIL: A platform-independent intermediate representation of disassembled code for static code analysis." Proceeding of CanSecWest (2009). 7. Lattner, Chris, andVikram Adve. "LLVM: A compilation framework for lifelong program analysis & transformation." Code Generation and Optimization, 2004. CGO 2004. International Symposium on. IEEE, 2004.
  • 54. References 8. Lopes, Bruno Cardoso, and Rafael Auler. Getting Started with LLVM Core Libraries. Packt Publishing Ltd, 2014. 9. Cadar, Cristian, Daniel Dunbar, and Dawson R. Engler. "KLEE: Unassisted and Automatic Generation of High-CoverageTests for Complex Systems Programs." OSDI.Vol. 8. 2008. 10. Anderson, Ross. "Why information security is hard-an economic perspective." Computer security applications conference, 2001. acsac 2001. proceedings 17th annual. IEEE, 2001.
  • 55. Questions?  Contact Information  Email: jones_malachi@bah.com  LinkedIn: https://www.linkedin.com/in/malachijonesphd