
Fuzzing Against the Machine: Automate vulnerability research with emulated IoT devices on QEMU
Author(s): Antonio Nappa (Author), Eduardo Blazquez (Author)
- Publisher: Packt Publishing
- Publication Date: 19 May 2023
- Language: English
- Print length: 238 pages
- ISBN-10: 1804614971
- ISBN-13: 9781804614976
Book Description
Find security flaws in any architecture effectively through emulation and fuzzing with QEMU and AFL
Purchase of the print or Kindle book includes a free PDF eBook
Key Features
- Understand the vulnerability landscape and useful tools such as QEMU and AFL
- Explore use cases to find vulnerabilities and execute unknown firmware
- Create your own firmware emulation and fuzzing environment to discover vulnerabilities
Book Description
Emulation and fuzzing are among the many techniques that can be used to improve cybersecurity; however, utilizing these efficiently can be tricky. Fuzzing Against the Machine is your hands-on guide to understanding how these powerful tools and techniques work. Using a variety of real-world use cases and practical examples, this book helps you grasp the fundamental concepts of fuzzing and emulation along with advanced vulnerability research, providing you with the tools and skills needed to find security flaws in your software.
The book begins by introducing you to two open source fuzzer engines: QEMU, which allows you to run software for whatever architecture you can think of, and American fuzzy lop (AFL) and its improved version AFL++. You’ll learn to combine these powerful tools to create your own emulation and fuzzing environment and then use it to discover vulnerabilities in various systems, such as iOS, Android, and Samsung’s Mobile Baseband software, Shannon. After reading the introductions and setting up your environment, you’ll be able to dive into whichever chapter you want, although the topics gradually become more advanced as the book progresses.
By the end of this book, you’ll have gained the skills, knowledge, and practice required to find flaws in any firmware by emulating and fuzzing it with QEMU and several fuzzing engines.
What you will learn
- Understand the difference between emulation and virtualization
- Discover the importance of emulation and fuzzing in cybersecurity
- Get to grips with fuzzing an entire operating system
- Discover how to inject a fuzzer into proprietary firmware
- Know the difference between static and dynamic fuzzing
- Look into combining QEMU with AFL and AFL++
- Explore Fuzz peripherals such as modems
- Find out how to identify vulnerabilities in OpenWrt
Who this book is for
This book is for security researchers, security professionals, embedded firmware engineers, and embedded software professionals. Learners interested in emulation, as well as software engineers interested in vulnerability research and exploitation, software testing, and embedded software development will also find it useful. The book assumes basic knowledge of programming (C and Python); operating systems (Linux and macOS); and the use of Linux shell, compilation, and debugging.
Table of Contents
- Who this book is for
- History of emulation
- Qemu from the ground
- Qemu Execution Modes and Fuzzing
- A Famous Refrain: AFL+QEMU = CVEs
- Modifying QEMU for basic instrumentation
- Real-life Case Study: Samsung Exynos Baseband
- Case Study: OpenWRT full system fuzzing
- Case Study: OpenWRT System Fuzzing for ARM
- Finally Here: iOS Full System Fuzzing
- Deus Ex Machina: Fuzzing Android Libraries
- Conclusion and Final Remarks
Editorial Reviews
Review
“In recent years, I focused on low-level software development: Linux kernel module, microcontroller firmware, LLVM/clang compiler contributions, and new features for high-energy physics analysis (production as of 2025). In this book, together with Antonio Nappa, Eduardo takes us into the journey of fuzzing embedded devices’ firmware using QEMU. He does so in an engaging manner, covering topics that range from an introduction to system emulation with QEMU, and the use of well-known tools such as AFL to practical hands-on use cases. The book includes interesting and relevant practical use cases such as fuzzing an OpenWrt-based firmware (which is used as a replacement in many routers) and vulnerability search in the firmware used in some commercial mobile phones. In summary, this book poses an excellent quick start in the area of fuzzing embedded devices’ firmware. Therefore, I’m proud to write the foreword to this book, which I’m sure will be helpful to many people. Enjoy reading!”
—
Dr. Javier López-Gómez
Senior Fellow in the Software for Physics Experiments group at CERN
“This book will take you through different stages, where the first part provides a base of concepts from vulnerabilities and exploitation to emulation. The next part will take you deeper into emulation and how it can be used in conjunction with fuzzing and help to understand how a vulnerability can be found based on a real-world example. The third and final part will then apply the concepts and knowledge of real systems with real-world examples for different types of systems.
This part is my favourite since it also dedicates a chapter to fuzzing an emulated iOS system. Altogether, you will learn about a decent number of concepts and techniques around emulation and fuzzing based on real examples, which are provided with great details and explanations. You will be able to base future research on the presented target systems or even new targets.”
—
Nikias Bassen VP of Product Security and iOS Research Team Leader at Zimperium, Inc.
About the Author
Antonio Nappa is an Application Analysis Team Leader at Zimperium Inc. He has been in the cybersecurity game since 17 years old. He holds a PhD in Software and Systems from the Madrid Institute of Advanced Studies. He has been a visiting scholar at UC Berkeley. His contributions have been published and recognized in international peer-reviewed venues. Since the DEFCON 2008 Finals, he never goes to sleep with a segfault.
Eduardo Blázquez is a PhD student of the University Carlos III of Madrid. He has been working in the cybersecurity area since 2017, with interests in Reverse Engineering and Malware Analysis. Currently, he is doing a PhD thesis about Android Security, but in his spare time he likes to study different topics like program analysis or operating system internals, and from time to time he likes to play different wargames about software exploitation.
Wow! eBook

