forked from image-rs/image-png
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
png-afl: document usage and minor tweaks, fixes image-rs#132
- Loading branch information
1 parent
f6fc66d
commit 8f4b884
Showing
4 changed files
with
25 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
out |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
|
||
## Build fuzzer binary | ||
|
||
RUSTFLAGS='-C codegen-units=1' cargo afl build | ||
|
||
NOTE: the RUSTFLAGS is only needed on Linux (and not if using gold linker), see https://github.com/rust-lang/rust/issues/53945 | ||
|
||
|
||
## Run fuzzer | ||
|
||
cargo afl fuzz -m 200 -i fuzzing_seeds -o out target/debug/png-afl | ||
|
||
NOTE: -m 200 sets memory limit to 200 mb. afl defaults to 50 megabytes memory usage. If we would not increase it, many invocations will exit with SIGABRT and look like crashes. | ||
|
||
|
||
### More info | ||
|
||
https://rust-fuzz.github.io/book/afl/tutorial.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters