O'Reilly logo

Beautiful Testing by Adam Goucher, Tim Riley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Fuzz Testing

Although fuzzing does not strictly require any setup, some preparation can make the technique much more effective.

Preparation

To get the best results from fuzz testing, you need a representative set of samples to use with the fuzzer. If you don’t already have a comprehensive set of documents, you should look for samples in your own bug tracker. These files are important because they have likely caused problems in the past—they are attached to bug reports, after all—and they may cause further trouble with some simple fuzzing.

Furthermore, these documents are already “known” to the developers in the sense that they can be easily retrieved and referenced with little effort. For example, if you use Bugzilla, you can add a quick statement about the original file when reporting new issues, such as: “The upcoming document is a fuzzed version of attachment 123 from bug 456.” Bugzilla will automatically link the “attachment 123” and “bug 456” text to the previous issue and existing file, making it easier for developers to consult them for further information if necessary.

Using fuzz testing to take advantage of this automatic management is also an elegant way to avoid problems with storing and tracking samples offline. Each file uploaded to the bug database gets a unique number that can be used to clearly and consistently reference it later on. Since the documents are already in the database, you also don’t need to worry about any privacy or confidentiality restrictions that so ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required