Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introduction to Fuzzing with AFL
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Ayush Priya
November 16, 2021
Technology
45
0
Share
Introduction to Fuzzing with AFL
This talk is an introduction to using AFL or American Fuzzy Lop to fuzz binaries.
Ayush Priya
November 16, 2021
More Decks by Ayush Priya
See All by Ayush Priya
Scrubbing PII from Logs in LogStash
ayushpriya10
0
840
Introduction to Deserialization Attacks
ayushpriya10
2
680
Web Assembly for Hackers
ayushpriya10
0
71
Other Decks in Technology
See All in Technology
AIでAIをテストする - 音声AIエージェントの品質保証戦略
morix1500
1
120
AgentCore×VPCでの設計パターンn選と勘所
har1101
3
280
No Types Needed, Just Callable Method Check
dak2
1
1.1k
Choose your own adventure in agentic design patterns
glaforge
0
130
Digitization部 紹介資料
sansan33
PRO
1
7.3k
みんなで作るAWS Tips 100連発 (FinOps編)
schwrzktz
1
300
ハーネスエンジニアリングをやりすぎた話 ~そのハーネスは解体された~
gotalab555
4
1.7k
M5Stack CoreS3とZephyr(RTOS)で Edge AIっぽいことしてみた
iotengineer22
0
150
AI時代のガードレールとしてのAPIガバナンス
nagix
0
280
Master Dataグループ紹介資料
sansan33
PRO
1
4.6k
AIを共同作業者にして書籍を執筆する方法 / How to Write a Book with AI as a Co-Creator
ama_ch
2
130
最近の技術系の話題で気になったもの色々(IoT系以外も) / IoTLT 花見予定会(たぶんBBQ) @都立潮風公園バーベキュー広場
you
PRO
1
240
Featured
See All Featured
Darren the Foodie - Storyboard
khoart
PRO
3
3.3k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
130
Fashionably flexible responsive web design (full day workshop)
malarkey
408
66k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.9k
How to build a perfect <img>
jonoalderson
1
5.4k
The SEO Collaboration Effect
kristinabergwall1
0
420
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.6k
[SF Ruby Conf 2025] Rails X
palkan
2
960
Utilizing Notion as your number one productivity tool
mfonobong
4
290
Transcript
Introduction to fuzzing with AFL
Ayush Priya VIT, Vellore @ayushpriya10 https://ayushpriya.com https://www.linkedin.com/in/ayushpriya10
What am I learning? • What is fuzzing and fuzzers?
• What is AFL? • How to use AFL?
Why am I learning this? • Discover undiscovered bugs •
Build a robust approach to development • (Maybe make some money)
What is Fuzzing? • A form of testing • Random
invalid input • Behaviour analysis
"You can find bugs in your sleep." - Craig Young
Why fuzz at all? • Unique test cases • Eliminates
methodology bias • Metrics - Code Coverage, Path Coverage
Types of fuzzers • Mutational • Grammar • Feedback-based
Introduction to AFL • Open-source • Smart fuzzer: PoC -
“Hello JPG”
Prerequisites • GCC, CLang • GDB, Exploitable • Screen •
Libtool-bin, automake, bison, libglib2.0-dev, qemu
Installation • Install AFL • Enable LLVM mode • Enable
QEMU mode
AFL Workflow • Compiling the binary with AFL’s compilers •
Building a Test Corpus • Running AFL on the target binary • Analyse findings
Compiling with AFL $ export CC=afl-clang-fast $ export AFL_HARDEN=1 $
export AFL_INST_RATIO=100 $ ./configure $ make
Building Test Corpus • Supplying test case(s) $ cp /bin/ps
afl_in/
Fuzzing with source • Build binary from source AFL •
Add test cases to afl_in • Fuzz! $ afl-fuzz -i in/ -o out/ -- ./bin @@
Parallel Fuzzing • One core per fuzzer • Check free
cores $ afl-fuzz -i in -o out -M f1 -- ./bin @@ $ afl-fuzz -i in -o out -S f2 -- ./bin @@
Output Structure • One folder per fuzzer • /crashes, /hangs,
/queue
Analysing AFL Screen
Hands-on • Clone fuzzgoat • Compile with AFL • Fuzz
in parallel • Check status
GDB and Exploitable • Open binary with GDB • Choose
a crash case • Run test case • Classify with Exploitable
Optimising Fuzzing • Execution Speed, Fail Fast • Isolate test
code • Minimise test cases • Minimise test files
Fuzzing a binary without source • Linux binaries • AFL’s
QEMU Mode
Limitations of AFL • Supports file/STDIN input • Supports selective
binaries • Supports selective OSs
Thanks!