Skip to content

Releases: crytic/fuzz-utils

0.2.0

02 Apr 13:23
ba33ab9
Compare
Choose a tag to compare

0.2.0 - 2024-04-02

This release adds support for automatic fuzzing harness generation, refactors a large part of the codebase, and introduces non-backwards compatible changes to the CLI. Each utility now has a separate command:

  • generate - used for generating Foundry unit tests
  • template - used to generate fuzzing harnesses
  • init - used to initialize a configuration file

A new CLI flag --config was added so that a configuration file can be used with the generate and template commands.
Three generation modes were added to the template command:

  • simple - The fuzzing harness will be generated with all of the state-changing functions from the target contracts. All function calls are performed directly, with the harness contract as the msg.sender.

  • prank - Similar to simple mode, with the difference that function calls are made from different users by using hevm.prank(). The users can be defined in the configuration file as "actors": ["0xb4b3", "0xb0b", ...]

  • actor - Actor contracts will be generated and all harness function calls will be proxied through these contracts. The Actor contracts can be considered as users of the target contracts and the functions included in these actors can be filtered by modifier, external calls, or by payable. This allows for granular control over user capabilities.

What's Changed

New features

Bug Fixes

Enhancements

Examples

New Contributors

Full Changelog: 0.1.0...0.2.0

0.1.0

16 Feb 10:26
f8368ea
Compare
Choose a tag to compare

0.1.0 - 2024-02-16

This is the first release of fuzz-utils, and experimental tool to speed up the invariants development process on smart contracts.

With this release, fuzz-utils allows to generate automatically Foundry unit tests from Echidna/Medusa broken properties