SlideShare a Scribd company logo
1 of 22
Download to read offline
CHIZPURFLE:
A GRAY-BOX ANDROID FUZZER
FOR VENDOR SERVICE CUSTOMIZATIONS
Antonio Ken Iannillo, Roberto Natella, Domenico Cotroneo, Cristina Nita-Rotaru
CHIZPURFLE is a reference to the wizarding world of J. K. Rowling
The 28th IEEE International Symposium on Software Reliability Engineering (ISSRE)
October 23-26,2017,Toulouse,France
Best Research Paper Award
ANDROID
• Android is the major OS for smartphones
• More than 20 Original Equipment Manufacturers (OEMs)
base their devices on theAndroid Open-Source Project
(AOSP)
• adding hardware and software customizations
• Vendor customizations often introduce new vendor-
specific software defects
• do not benefit from the feedback loop of the Android ecosystem
• Vendors’ customizations are often code runningwith
special privileges
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 1
ANDROID VENDOR CUSTOMIZATIONS
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 2
device drivers,stock applications,and system services
69%
31%
Samsung Galaxy S6 Edge
45%
55%
Huawei P8 Lite
28%
72%
HTC One M9
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 3
FUZZING
WELL-ESTABLISHED AND EFFECTIVE
TESTING TECHNIQUE
TO IDENTIFY WEAKNESSES IN FRAGILE
SOFTWARE INTERFACES
BY INJECTING
INVALID AND UNEXPECTED INPUTS
BLACK-BOX
easy to
implement
• random
inputs, or
• grammar-
based inputs
low
coverage
• may
repeatedly
execute the
same code
paths over
and over
high
coverage
• exploits the
visibility of
the paths
covered by
the tests
hard to
implement
• needs source
code, or
• needs the
ability to run
in virtualized
environments
WHITE-BOX
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 4
FUZZING
Vendor customizations do not provide source
code, and cannot run on a device emulator!
CHIZPURFLE: A GRAY-BOX SOLUTION
• Chizpurfle is a fuzzing tool designed
to run on the actual device from
the vendor
• no need for recompiling the target code
• no execution in a special environment
• It automatically identifies and fuzzes
vendor customizations on the
deviceChizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 5
ARCHITECTURE OF CHIZPURFLE
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 6
ANDROID DEVICE
METHOD
EXTRACTOR
INSTRUMENTATION
MODULE
SEED
MANAGER
FUZZ INPUT
GENERATOR
TEST
EXECUTOR
OUTPUT
ANALYZER
STORAGE
ORCHESTRATOR
SYSTEM SERVICE
Identifies the Android
services that have been
added or modified by the
vendor
ARCHITECTURE OF CHIZPURFLE
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 7
ANDROID DEVICE
METHOD
EXTRACTOR
INSTRUMENTATION
MODULE
SEED
MANAGER
FUZZ INPUT
GENERATOR
TEST
EXECUTOR
OUTPUT
ANALYZER
STORAGE
ORCHESTRATOR
SYSTEM SERVICE
This loop iterates over service inputs
to maximize the test coverage
Computes the test score for
every tested input (the more
new blocks are covered, the
higher the score)
Keeps track of test coverage
(using dynamic binary
instrumentation)
CHIZPURFLE TARGET PROCESS
INSTRUM.
MODULE
STALKER
SERVER
PROCESS
THREAD
for each test
for each block
DYN LIB INJECT
FOLLOW
INJECT
START
STOP
ADDRESSES
REWRITE
BLOCK
ADDRESS
CHIZPURFLE:
INSTRUMENTATION
MODULE
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 8
The instrumentation module injects a
small server (“stalker”) in the target
process using ptrace()
Before a code block is executed,the
stalker rewrites the branch
instructions in the block,replacing
them with a branch to the stalker’s
code (in order to instrument the next
code block, and to track coverage)
mov x29, sp
mov x3, x30
ldp x29,x30,[sp],16
stp x29,x30,[sp-16]!
add x30,x0,#4
save address
stalk (bl f_label)
save address
stalk(ret)
mov x29, sp
mov x3, x30
ldp x29,x30,[sp],16
stp x29,x30,[sp-16]!
add x30,x0,#4
ret
bl f_label
Block
(before rewriting)
Block
(after rewriting)
CHIZPURFLE:
FUZZ INPUT GENERATOR
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 9
The seed manager generates
new test inputs, by mutating
previous test inputs that
increased the test coverage (the
test score π)
Previous test inputs are randomly
selected: the higher the test score
π, the higher the probability of
selecting that test input
com.samsung.android.cocktailbar.ICocktailBarService
{
"name":"updateCocktail",
"parameters":[
"java.lang.String",
"com.samsung.android.cocktailbar.CocktailInfo",
"int”
]
}
“string” a CocktailInfo object 2
• Random
• Substring
• Truncate
• Substitute Char
• Very long string
• Null
• New object
with random
values
• Fuzz field
values
• Random
• Zero
• One
• Add/Sub
Random
Delta
• Max value
• Min value
EVALUATION CAMPAIGN
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 10
Samsung Galaxy S6 Edge – Android 7.0 Nougat
FUZZ TESTING CAMPAIGN
• Chizpurfle detected 2,272 service methods
from Samsung customizations
• Chizpurfle performed 34,645 tests on these
methods
• Found failures were critical
• 9 tests failed, due to 2 distinct bugs
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 11
BUGS IN SAMSUNG S6 EDGE
(CASE 1)
System Server process
reboots à Smartphone
reboots
FATAL EXCEPTION
(NullPointerException)
Not trivial input,detected by
the gray-box approach
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 12
SPENGESTURE SERVICE
injectInput(…, android.view.InputEvent [ ], ...)
android.view.InputEvent array is
non-null and non-empty, and at
least one of its elements is null
REBOOT
BUGS IN SAMSUNG S6 EDGE
(CASE 2)
Phone process crashes à
Call interrupted
SQLite-Exception
input strings that include
specific SQL control
expressions (such as single
quotes),triggering an SQL
injection
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 13
VOIP SERVICE
callInVoIP(String SIPAddress)
SELECT reject_number FROM
reject_num WHERE reject
number=’001?u0 [...a random string
with a single quote...]
CRASH
MEASUREMENTS
• throughput
• code coverage
ANDROID DEVICE
METHOD
EXTRACTOR
SEED
MANAGER
FUZZ INPUT
GENERATOR
TEST
EXECUTOR
STORAGE
ORCHESTRATOR
SYSTEM SERVICE
PERFORMANCE EVALUATION METHODOLOGY
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 14
INSTRUMENTATION
MODULE
OUTPUT
ANALYZER
MEASUREMENTS
PERFORMANCE
OVERHEAD
• throughput
• code coverage
• How much more
time does Chizpurfle
take compared to a
black-box approach?
ANDROID DEVICE
METHOD
EXTRACTOR
SEED
MANAGER
FUZZ INPUT
GENERATOR
TEST
EXECUTOR
STORAGE
ORCHESTRATOR
SYSTEM SERVICE
PERFORMANCE EVALUATION METHODOLOGY
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 15
INSTRUMENTATION
MODULE
OUTPUT
ANALYZER
we simulate a black-box fuzzer, by
disabling the instrumentation module
and the coverage analysis
MEASUREMENTS
PERFORMANCE
OVERHEAD
COVERAGE
GAIN
• throughput
• code coverage
• How much more
time does Chizpurfle
take compared to a
black-box approach?
• How much more
code does Chizpurfle
cover compared to a
black-box approach?
ANDROID DEVICE
METHOD
EXTRACTOR
SEED
MANAGER
FUZZ INPUT
GENERATOR
TEST
EXECUTOR
STORAGE
ORCHESTRATOR
SYSTEM SERVICE
PERFORMANCE EVALUATION METHODOLOGY
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 16
INSTRUMENTATION
MODULE
OUTPUT
ANALYZER
we again simulate a black-box fuzzer; we still generate
black-box inputs (no feedback from the test score), but
we enable the instrumentation module to measure the
coverage of black-box fuzzing
PERFORMANCE EVALUATION
METHODOLOGY
Throughput
Chizpurfle ChizpurfleBB
In ChizpurfleBB,the inputs are
generated randomly
we used ChizpurfleBB by
applyingthe same number
of inputs that were also
generated by the gray-box
Chizpurfle for the same
methods,and compared the
execution times (T andT’)
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 17
T
T’
PERFORMANCE EVALUATION
METHODOLOGY
In ChizpurfleBB+COV,
instrumentation is active
we compensate for the
slowdown due to
instrumentation by granting
ChizpurfleBB+COV a higher
time budget than gray-box
Chizpurfle fuzzing.
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 18
Code Coverage
Chizpurfle ChizpurfleBB+COV
C
C’
T T(1+T/T’)
CODE
COVERAGE GAIN
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 19
On average, Chizpurfle covers 2.3x more code
PERFORMANCE
OVERHEAD
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 20
On average, Chizpurfle has an execution slow-down of 11.97x
CONCLUSION
• Chizpurfle,a novel gray-box fuzzer designed to test custom system services
fromAndroid vendors
• The gray-box approach can discover relevant vulnerabilities,it has a reasonable
overhead,and it can increase the test coverage compared to the black-box
approach
• Opportunity for research on fuzzing in mobile devices,by allowing to
experiment with different heuristics for evolutionary fuzzing (e.g.,for
determining when to stop fuzzing,for prioritizing seeds,and for selecting fuzz
operators)
Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 21

More Related Content

Similar to Chizpurfle: A Gray-Box Android Fuzzer for Vendor Service Customizations

Mining Assumptions for Software Components using Machine Learning
Mining Assumptions for Software Components using Machine LearningMining Assumptions for Software Components using Machine Learning
Mining Assumptions for Software Components using Machine LearningLionel Briand
 
Innovation day 2013 2.3 rudy van raemdonck (verhaert) - rapid prototyping o...
Innovation day 2013   2.3 rudy van raemdonck (verhaert) - rapid prototyping o...Innovation day 2013   2.3 rudy van raemdonck (verhaert) - rapid prototyping o...
Innovation day 2013 2.3 rudy van raemdonck (verhaert) - rapid prototyping o...Verhaert Masters in Innovation
 
General Platform Platform Isolator
General Platform Platform IsolatorGeneral Platform Platform Isolator
General Platform Platform IsolatorEsco Group
 
The DEBS Grand Challenge 2017
The DEBS Grand Challenge 2017The DEBS Grand Challenge 2017
The DEBS Grand Challenge 2017Roman Katerinenko
 
Deterministic and high throughput data processing for CubeSats
Deterministic and high throughput data processing for CubeSatsDeterministic and high throughput data processing for CubeSats
Deterministic and high throughput data processing for CubeSatsPablo Ghiglino
 
Building management system (bms)
Building management system (bms)Building management system (bms)
Building management system (bms)slmnsvn
 
Inside Matters - 3D X-Ray Microscopy - Software - Octopus Imaging
Inside Matters - 3D X-Ray Microscopy - Software - Octopus ImagingInside Matters - 3D X-Ray Microscopy - Software - Octopus Imaging
Inside Matters - 3D X-Ray Microscopy - Software - Octopus ImagingLeiv Hendrickx
 
L1_Introduction.ppt
L1_Introduction.pptL1_Introduction.ppt
L1_Introduction.pptVarsha506533
 
Testing of Cyber-Physical Systems: Diversity-driven Strategies
Testing of Cyber-Physical Systems: Diversity-driven StrategiesTesting of Cyber-Physical Systems: Diversity-driven Strategies
Testing of Cyber-Physical Systems: Diversity-driven StrategiesLionel Briand
 
STREAM-0D: a new vision for Zero-Defect Manufacturing
STREAM-0D: a new vision for Zero-Defect ManufacturingSTREAM-0D: a new vision for Zero-Defect Manufacturing
STREAM-0D: a new vision for Zero-Defect ManufacturingFulvio Bernardini
 
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...Yole Developpement
 
智慧檢測技術與工業自動化
智慧檢測技術與工業自動化智慧檢測技術與工業自動化
智慧檢測技術與工業自動化CHENHuiMei
 
Design Patterns Facilitated by Geode's WAN Distribution
Design Patterns Facilitated by Geode's WAN DistributionDesign Patterns Facilitated by Geode's WAN Distribution
Design Patterns Facilitated by Geode's WAN DistributionVMware Tanzu
 
Autonomous robotics based on simple sensor inputs.
Autonomous robotics based on simplesensor inputs.Autonomous robotics based on simplesensor inputs.
Autonomous robotics based on simple sensor inputs. sathish sak
 
Design of Fuzzy PID controller to control DC motor with zero overshoot
Design of Fuzzy PID controller to control DC motor with zero overshootDesign of Fuzzy PID controller to control DC motor with zero overshoot
Design of Fuzzy PID controller to control DC motor with zero overshootIJERA Editor
 
API company presentation
API  company presentationAPI  company presentation
API company presentationEric Ma
 
Ladder for mixed signal test engineers
Ladder for mixed signal test engineersLadder for mixed signal test engineers
Ladder for mixed signal test engineersFangXuIEEE
 

Similar to Chizpurfle: A Gray-Box Android Fuzzer for Vendor Service Customizations (20)

Mining Assumptions for Software Components using Machine Learning
Mining Assumptions for Software Components using Machine LearningMining Assumptions for Software Components using Machine Learning
Mining Assumptions for Software Components using Machine Learning
 
Innovation day 2013 2.3 rudy van raemdonck (verhaert) - rapid prototyping o...
Innovation day 2013   2.3 rudy van raemdonck (verhaert) - rapid prototyping o...Innovation day 2013   2.3 rudy van raemdonck (verhaert) - rapid prototyping o...
Innovation day 2013 2.3 rudy van raemdonck (verhaert) - rapid prototyping o...
 
General Platform Platform Isolator
General Platform Platform IsolatorGeneral Platform Platform Isolator
General Platform Platform Isolator
 
The DEBS Grand Challenge 2017
The DEBS Grand Challenge 2017The DEBS Grand Challenge 2017
The DEBS Grand Challenge 2017
 
Dualis Contour Brochure
Dualis Contour BrochureDualis Contour Brochure
Dualis Contour Brochure
 
Deterministic and high throughput data processing for CubeSats
Deterministic and high throughput data processing for CubeSatsDeterministic and high throughput data processing for CubeSats
Deterministic and high throughput data processing for CubeSats
 
Building management system (bms)
Building management system (bms)Building management system (bms)
Building management system (bms)
 
Inside Matters - 3D X-Ray Microscopy - Software - Octopus Imaging
Inside Matters - 3D X-Ray Microscopy - Software - Octopus ImagingInside Matters - 3D X-Ray Microscopy - Software - Octopus Imaging
Inside Matters - 3D X-Ray Microscopy - Software - Octopus Imaging
 
L1_Introduction.ppt
L1_Introduction.pptL1_Introduction.ppt
L1_Introduction.ppt
 
Testing of Cyber-Physical Systems: Diversity-driven Strategies
Testing of Cyber-Physical Systems: Diversity-driven StrategiesTesting of Cyber-Physical Systems: Diversity-driven Strategies
Testing of Cyber-Physical Systems: Diversity-driven Strategies
 
ADCSS 2022
ADCSS 2022ADCSS 2022
ADCSS 2022
 
STREAM-0D: a new vision for Zero-Defect Manufacturing
STREAM-0D: a new vision for Zero-Defect ManufacturingSTREAM-0D: a new vision for Zero-Defect Manufacturing
STREAM-0D: a new vision for Zero-Defect Manufacturing
 
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...
Yole Intel RealSense 3D camera module and STM IR laser 2015 teardown reverse ...
 
resumelrs_jan_2017
resumelrs_jan_2017resumelrs_jan_2017
resumelrs_jan_2017
 
智慧檢測技術與工業自動化
智慧檢測技術與工業自動化智慧檢測技術與工業自動化
智慧檢測技術與工業自動化
 
Design Patterns Facilitated by Geode's WAN Distribution
Design Patterns Facilitated by Geode's WAN DistributionDesign Patterns Facilitated by Geode's WAN Distribution
Design Patterns Facilitated by Geode's WAN Distribution
 
Autonomous robotics based on simple sensor inputs.
Autonomous robotics based on simplesensor inputs.Autonomous robotics based on simplesensor inputs.
Autonomous robotics based on simple sensor inputs.
 
Design of Fuzzy PID controller to control DC motor with zero overshoot
Design of Fuzzy PID controller to control DC motor with zero overshootDesign of Fuzzy PID controller to control DC motor with zero overshoot
Design of Fuzzy PID controller to control DC motor with zero overshoot
 
API company presentation
API  company presentationAPI  company presentation
API company presentation
 
Ladder for mixed signal test engineers
Ladder for mixed signal test engineersLadder for mixed signal test engineers
Ladder for mixed signal test engineers
 

Recently uploaded

ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEOrtus Solutions, Corp
 
software engineering Chapter 5 System modeling.pptx
software engineering Chapter 5 System modeling.pptxsoftware engineering Chapter 5 System modeling.pptx
software engineering Chapter 5 System modeling.pptxnada99848
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Andreas Granig
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxTier1 app
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaHanief Utama
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - InfographicHr365.us smith
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 

Recently uploaded (20)

ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
 
software engineering Chapter 5 System modeling.pptx
software engineering Chapter 5 System modeling.pptxsoftware engineering Chapter 5 System modeling.pptx
software engineering Chapter 5 System modeling.pptx
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief Utama
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - Infographic
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 

Chizpurfle: A Gray-Box Android Fuzzer for Vendor Service Customizations

  • 1. CHIZPURFLE: A GRAY-BOX ANDROID FUZZER FOR VENDOR SERVICE CUSTOMIZATIONS Antonio Ken Iannillo, Roberto Natella, Domenico Cotroneo, Cristina Nita-Rotaru CHIZPURFLE is a reference to the wizarding world of J. K. Rowling The 28th IEEE International Symposium on Software Reliability Engineering (ISSRE) October 23-26,2017,Toulouse,France Best Research Paper Award
  • 2. ANDROID • Android is the major OS for smartphones • More than 20 Original Equipment Manufacturers (OEMs) base their devices on theAndroid Open-Source Project (AOSP) • adding hardware and software customizations • Vendor customizations often introduce new vendor- specific software defects • do not benefit from the feedback loop of the Android ecosystem • Vendors’ customizations are often code runningwith special privileges Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 1
  • 3. ANDROID VENDOR CUSTOMIZATIONS Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 2 device drivers,stock applications,and system services 69% 31% Samsung Galaxy S6 Edge 45% 55% Huawei P8 Lite 28% 72% HTC One M9
  • 4. Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 3 FUZZING WELL-ESTABLISHED AND EFFECTIVE TESTING TECHNIQUE TO IDENTIFY WEAKNESSES IN FRAGILE SOFTWARE INTERFACES BY INJECTING INVALID AND UNEXPECTED INPUTS
  • 5. BLACK-BOX easy to implement • random inputs, or • grammar- based inputs low coverage • may repeatedly execute the same code paths over and over high coverage • exploits the visibility of the paths covered by the tests hard to implement • needs source code, or • needs the ability to run in virtualized environments WHITE-BOX Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 4 FUZZING Vendor customizations do not provide source code, and cannot run on a device emulator!
  • 6. CHIZPURFLE: A GRAY-BOX SOLUTION • Chizpurfle is a fuzzing tool designed to run on the actual device from the vendor • no need for recompiling the target code • no execution in a special environment • It automatically identifies and fuzzes vendor customizations on the deviceChizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 5
  • 7. ARCHITECTURE OF CHIZPURFLE Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 6 ANDROID DEVICE METHOD EXTRACTOR INSTRUMENTATION MODULE SEED MANAGER FUZZ INPUT GENERATOR TEST EXECUTOR OUTPUT ANALYZER STORAGE ORCHESTRATOR SYSTEM SERVICE Identifies the Android services that have been added or modified by the vendor
  • 8. ARCHITECTURE OF CHIZPURFLE Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 7 ANDROID DEVICE METHOD EXTRACTOR INSTRUMENTATION MODULE SEED MANAGER FUZZ INPUT GENERATOR TEST EXECUTOR OUTPUT ANALYZER STORAGE ORCHESTRATOR SYSTEM SERVICE This loop iterates over service inputs to maximize the test coverage Computes the test score for every tested input (the more new blocks are covered, the higher the score) Keeps track of test coverage (using dynamic binary instrumentation)
  • 9. CHIZPURFLE TARGET PROCESS INSTRUM. MODULE STALKER SERVER PROCESS THREAD for each test for each block DYN LIB INJECT FOLLOW INJECT START STOP ADDRESSES REWRITE BLOCK ADDRESS CHIZPURFLE: INSTRUMENTATION MODULE Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 8 The instrumentation module injects a small server (“stalker”) in the target process using ptrace() Before a code block is executed,the stalker rewrites the branch instructions in the block,replacing them with a branch to the stalker’s code (in order to instrument the next code block, and to track coverage) mov x29, sp mov x3, x30 ldp x29,x30,[sp],16 stp x29,x30,[sp-16]! add x30,x0,#4 save address stalk (bl f_label) save address stalk(ret) mov x29, sp mov x3, x30 ldp x29,x30,[sp],16 stp x29,x30,[sp-16]! add x30,x0,#4 ret bl f_label Block (before rewriting) Block (after rewriting)
  • 10. CHIZPURFLE: FUZZ INPUT GENERATOR Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 9 The seed manager generates new test inputs, by mutating previous test inputs that increased the test coverage (the test score π) Previous test inputs are randomly selected: the higher the test score π, the higher the probability of selecting that test input com.samsung.android.cocktailbar.ICocktailBarService { "name":"updateCocktail", "parameters":[ "java.lang.String", "com.samsung.android.cocktailbar.CocktailInfo", "int” ] } “string” a CocktailInfo object 2 • Random • Substring • Truncate • Substitute Char • Very long string • Null • New object with random values • Fuzz field values • Random • Zero • One • Add/Sub Random Delta • Max value • Min value
  • 11. EVALUATION CAMPAIGN Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 10 Samsung Galaxy S6 Edge – Android 7.0 Nougat
  • 12. FUZZ TESTING CAMPAIGN • Chizpurfle detected 2,272 service methods from Samsung customizations • Chizpurfle performed 34,645 tests on these methods • Found failures were critical • 9 tests failed, due to 2 distinct bugs Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 11
  • 13. BUGS IN SAMSUNG S6 EDGE (CASE 1) System Server process reboots à Smartphone reboots FATAL EXCEPTION (NullPointerException) Not trivial input,detected by the gray-box approach Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 12 SPENGESTURE SERVICE injectInput(…, android.view.InputEvent [ ], ...) android.view.InputEvent array is non-null and non-empty, and at least one of its elements is null REBOOT
  • 14. BUGS IN SAMSUNG S6 EDGE (CASE 2) Phone process crashes à Call interrupted SQLite-Exception input strings that include specific SQL control expressions (such as single quotes),triggering an SQL injection Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 13 VOIP SERVICE callInVoIP(String SIPAddress) SELECT reject_number FROM reject_num WHERE reject number=’001?u0 [...a random string with a single quote...] CRASH
  • 15. MEASUREMENTS • throughput • code coverage ANDROID DEVICE METHOD EXTRACTOR SEED MANAGER FUZZ INPUT GENERATOR TEST EXECUTOR STORAGE ORCHESTRATOR SYSTEM SERVICE PERFORMANCE EVALUATION METHODOLOGY Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 14 INSTRUMENTATION MODULE OUTPUT ANALYZER
  • 16. MEASUREMENTS PERFORMANCE OVERHEAD • throughput • code coverage • How much more time does Chizpurfle take compared to a black-box approach? ANDROID DEVICE METHOD EXTRACTOR SEED MANAGER FUZZ INPUT GENERATOR TEST EXECUTOR STORAGE ORCHESTRATOR SYSTEM SERVICE PERFORMANCE EVALUATION METHODOLOGY Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 15 INSTRUMENTATION MODULE OUTPUT ANALYZER we simulate a black-box fuzzer, by disabling the instrumentation module and the coverage analysis
  • 17. MEASUREMENTS PERFORMANCE OVERHEAD COVERAGE GAIN • throughput • code coverage • How much more time does Chizpurfle take compared to a black-box approach? • How much more code does Chizpurfle cover compared to a black-box approach? ANDROID DEVICE METHOD EXTRACTOR SEED MANAGER FUZZ INPUT GENERATOR TEST EXECUTOR STORAGE ORCHESTRATOR SYSTEM SERVICE PERFORMANCE EVALUATION METHODOLOGY Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 16 INSTRUMENTATION MODULE OUTPUT ANALYZER we again simulate a black-box fuzzer; we still generate black-box inputs (no feedback from the test score), but we enable the instrumentation module to measure the coverage of black-box fuzzing
  • 18. PERFORMANCE EVALUATION METHODOLOGY Throughput Chizpurfle ChizpurfleBB In ChizpurfleBB,the inputs are generated randomly we used ChizpurfleBB by applyingthe same number of inputs that were also generated by the gray-box Chizpurfle for the same methods,and compared the execution times (T andT’) Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 17 T T’
  • 19. PERFORMANCE EVALUATION METHODOLOGY In ChizpurfleBB+COV, instrumentation is active we compensate for the slowdown due to instrumentation by granting ChizpurfleBB+COV a higher time budget than gray-box Chizpurfle fuzzing. Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 18 Code Coverage Chizpurfle ChizpurfleBB+COV C C’ T T(1+T/T’)
  • 20. CODE COVERAGE GAIN Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 19 On average, Chizpurfle covers 2.3x more code
  • 21. PERFORMANCE OVERHEAD Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 20 On average, Chizpurfle has an execution slow-down of 11.97x
  • 22. CONCLUSION • Chizpurfle,a novel gray-box fuzzer designed to test custom system services fromAndroid vendors • The gray-box approach can discover relevant vulnerabilities,it has a reasonable overhead,and it can increase the test coverage compared to the black-box approach • Opportunity for research on fuzzing in mobile devices,by allowing to experiment with different heuristics for evolutionary fuzzing (e.g.,for determining when to stop fuzzing,for prioritizing seeds,and for selecting fuzz operators) Chizpurfle: a Gray-Box Android Fuzzer for Vendor Service Customizations 21