How to debug failed Mayhem runs

Welcome to Mayhem Tips and Tricks series! Our goal is to help you learn about the best features of Mayhem in small bite-size chunks. Today, we will explain how you can debug failed Mayhem runs.

Your targets would never fail and work the first time in a perfect world. However, real-world software is complicated, and you may fail on the first try. Fortunately, Mayhem provides information that can be crucial to understanding why a run failed in Mayhem.

Mayhem generates a strace log, stdout, and stderr log that you can download and review when a run fails. These logs can usually clue you into the underlying problem. In addition, depending on your target, Mayhem generates a coverage file which is helpful if your target is failing at a specific point in the code due to misconfiguration or a missing external dependency.

You can access the logs in one of two ways. First, if your run fails, you will probably see a message similar to the one below. By clicking on “View Related Artifacts,” you’ll be given the option to download any logs that Mayhem generated. Below, this failing run generated a coverage file, a stdout log, and a strace log.

\ 600x215

You can also access more information about the run and logs by viewing the “Event Log”:

\ 376x219

Some targets can be tricky to configure correctly because of the complex nature of real-world software. Fortunately, Mayhem provides all the information you need to debug failed runs.

We hope that you found this Tips and Tricks article helpful.