You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7Lines changed: 7 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -69,6 +69,13 @@ The `template` command is used to generate a fuzzing harness. The harness can in
69
69
-`-c`/`--contracts``target_contracts: list`: The name of the target contract.
70
70
-`-o`/`--output-dir``output_directory: str`: Output directory name. By default it is `fuzzing`
71
71
-`--config`: Path to the `fuzz-utils` config JSON file
72
+
-`--mode`: The strategy to use when generating the harnesses. Valid options: `simple`, `prank`, `actor`
73
+
74
+
**Generation modes**
75
+
The tool support three harness generation strategies:
76
+
-`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`.
77
+
-`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", ...]`
78
+
-`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.
0 commit comments