1308 Commits

Author SHA1 Message Date
Romain Malmain
4f5ca8f8e2
Fix cmplog for qemu fork executor (#3145)
* update cmplog map ptr

* do not lower it; it's still there so it should be working
2025-04-09 15:25:13 +02:00
Romain Malmain
7680ea1346
Safe qemu cpu from index (#2941)
* safe cpu from index

* add comment
2025-04-09 14:43:26 +02:00
Romain Malmain
fb8939eefc
Fix fork bug in libafl qemu (#3109)
* fix fork bug

* lol

* fix

* lower it; we're gonna move from this anyway

---------

Co-authored-by: Dongjia "toka" Zhang <tokazerkje@outlook.com>
2025-04-08 19:08:40 +02:00
lazymio
bfc55c98a7
Enable SIMD acceleration for stable rust toolchain (#3140)
* initial support

* migrate SAND

* Update comments

* Fmt

* Clippy

* Fix missing docs

* fmt fix

* clippy again

* weird clippy

* clippy

* Fix

* Allow new SIMDMapFeedback

* Fix features

* Fix features again

* Allow custom names

* Fix imports

* Fix imports

* Fmt

* Fix missing implementations

* Requires std to simd

* DO NOT Overwrite names

* Format toml

* no_std fix

* fmt

* Use SIMDMapFeedback for libfuzzer_libpng

* no_std (?)

* clippy

* fix no_alloc

* allow cargo docs to enable all features

* clippy again

* Fix missing import

* Fix cargo docs

* Naive simplify_map doesn't require wide

* Accidentally commit the file

* more fine grined features

* Fix clippy.ps1

* Fix wide256 for simplify_map

* Renaming to SimdMapFeedback

* Dynamic dispatch

* Fix naming

* Move to simd.rs

* clippy

* clippy

* dispatch earlier

* Fix clippy

* clippy

* clippy

* Revert previous change

* Fix comments

* Update comments for std_covmap_is_interesting

* remove SIMD and choose fastest implementation based on target_arch

* no longer nightly imports

* Fix

* upstream benchmark code

* Fix docs

* Fix libfuzzer_libpng

* Disable clippy for benchmark

* clippy

* clippy again

---------

Co-authored-by: Dongjia "toka" Zhang <tokazerkje@outlook.com>
2025-04-08 19:08:16 +02:00
lazymio
fa8a576ef0
Introduce HasAflStyleTargetArguments and restore parse_afl_cmdline for CommandExecutor (#3125)
* Introduce HasAflStyleTargetArguments and restore parse_afl_cmdline for CommandExecutor

* clippy

* Fix imports

* Move envs to the shared trait

* Move to a standalone file

* Format

* Gate via std and unix

* Fix

* clippy

* move InputLocation to afl_args

* clippy

* Fix

* fmt

* Fix more

* Shall last missing

* Rename to AflTargetArgs

* Fmt

* move AflTargetArgs to libafl_bolts and adapt CMainArgsBuilder to use it

* use_stdin is no longer needed

* leaveout

* Fix again

* Renaming

* Leave out lib.rs

* Leave out fmt

---------

Co-authored-by: Dongjia "toka" Zhang <tokazerkje@outlook.com>
2025-04-08 13:19:44 +02:00
Daniel Hajjar
ec24513c95
Add RISC-V support to libafl_unicorn (#3134) 2025-04-07 16:18:10 +02:00
Dongjia "toka" Zhang
c99371fd20
Fix tiny inst (#3126)
* fix tn inst

* add

* fix more
2025-04-03 16:22:25 +02:00
Romain Malmain
9dff7a438d
Add client stats to Events (#3116)
* add stats alongside Event over the wire
2025-04-01 16:51:52 +02:00
Dongjia "toka" Zhang
b67bd1792f
update libnyx (#3111)
* apude

* lock
2025-03-27 13:25:58 +01:00
dkoch144
f700aac911
Enable building libpng on CI without using GUI (#3110)
* Fixing windows ci build in justfile. harness.cc modified for cl.exe. Additions to README.

* More precise compiler check for noinline definition.

---------

Co-authored-by: dkoch <dkoch@vigilantsys.com>
2025-03-26 22:16:06 +01:00
Dongjia "toka" Zhang
bd12639f8e
0.15.2 (#3104)
* 0.15.2

* miri

* mistake

* unsafe

* lock file
2025-03-25 13:30:15 +01:00
Dongjia "toka" Zhang
60d0ccb8cb
Commandline args handling for binary only target on libafl_qemu (#3098)
* POC

* POC

* pin the obj

* add map_input_to_memory

* still trying to get things to work

* Justfile

* lol

* nah bad idea

* done

* revert

* revert

* lol

* Move to libafl_qemu

* a

* add

* add

* lol

* clp

* a

* tmate

* Thank you bash I love you

* aaaaaaaa

* a

* bbb
2025-03-21 18:43:08 +01:00
Dongjia "toka" Zhang
f73d47dfb8
More stable just test for libfuzzer_stb_image_sugar (#3097)
* aa

* tab to space

* bash syntax is ❤❤❤❤
2025-03-20 15:10:14 +01:00
WorksButNotTested
30946641cd
Add filter to ASAN module in qemu_launcher (#3089)
also add filters to rasan runner.

Co-authored-by: Your Name <you@example.com>
2025-03-19 16:13:45 +01:00
Romain Malmain
d5ddc1359e
Fix qemu snapshot module unmap (#3084)
* fix qemu usermode snapshot unmap

* fix phys addr computation for qemu. some cleanup.
2025-03-18 10:31:16 +01:00
Romain Malmain
d67296f34e
Soft recovery from crashes in libafl qemu usermode (#3073)
* soft recovery from crashes in qemu

* regen bindings for clippy

* configurable crash behaviour
2025-03-14 16:56:03 +01:00
Romain Malmain
85bcafa831
Track lockfiles (#3015)
* rename libafl_fmt into liabfl_repo_tools

* add option to generate lockfiles

* only keep binary lockfiles (update gitignore)
2025-03-13 12:32:09 +01:00
Dongjia "toka" Zhang
f3da9da7bf
Fix metadata addition when solution is found (#3069)
* fix

* fixer
2025-03-12 13:57:06 +01:00
Dongjia "toka" Zhang
ff8a5b3baa
Fix wrong path in Justfile (#3068) 2025-03-11 18:58:53 +01:00
Dongjia "toka" Zhang
226a20e6cf
Fix usage of TracingStage (#3062)
* real fix

* more

* debug

* fix

* fixer

* mmmm

* mm

* mm

* mm

* fix

* fix atheris

* ?
2025-03-11 14:37:19 +01:00
WorksButNotTested
728b1216bb
Librasan (#3023)
* Fixes to main

* Add librasan

* Party like it's 2024

* Fix snapshot module to work with guest asan

* Fix guest_asan module

* Fixes to runner

* Fix linking issues using a REL

* Fix qemu_launcher

* Change modify_mapping to a method

* Fix gasan_test

* Remove debug from Justfile

* Optimize release build of librasan

* Set ulimit for qasan and gasan tests

* Tidy up symbol renaming

* Add missing symbols for PPC

* Change to support rustix 1.0.0

* Canonicalize the CUSTOM_ASAN_PATH

* Review changes

* Restructure backends

* release_max_level_info

* More review changes

* Clippy fixes

* Changes to reduce the burden on the CI

* Fix macos clippy

---------

Co-authored-by: Your Name <you@example.com>
2025-03-10 17:27:55 +01:00
Dongjia "toka" Zhang
15da05f8e8
Cleanup for #3035 (#3059) 2025-03-10 14:09:54 +01:00
Dongjia "toka" Zhang
620500e295
Remove AdaptiveSerializer, Send off interesting testcase from crash handler, Add clearer error message (#3053)
* clean

* test thread 1

* add some error messages

* mm

* std

* mm

* aa

* pp

* fix

* change fuzzers

* fix

---------

Co-authored-by: Your Name <you@example.com>
2025-03-08 20:12:16 +01:00
lazymio
de2bc166f0
Implementation of SAND: Decoupling Sanitization from Fuzzing for Low Overhead (#3037)
* Reference implementation of SAND: Decoupling Sanitization from Fuzzing for Low Overhead

* Format code

* make clippy happy

* Update docs

* clean output

* fmt

* Fix for nostd

* Update docs

* use use alloc::vec::Vec;

* Docs updates

* Update docs

* Format toml

* Format again

* Add CI

* Rename run_targets to run_target_all

* Update docs

* Update justfile to test fuzzer

* left out justfile

* Format

* Corner case when bitmap size is as small as 1

* Add comments

* clippy

* Format vuln.c

* Format toml

* Fix doc

* Fix justfile

* Move ExecutorsTuple to executors/mod.rs

* Fix

---------

Co-authored-by: Dongjia "toka" Zhang <tokazerkje@outlook.com>
2025-03-06 14:15:22 +01:00
Dongjia "toka" Zhang
977ff10a0f
Make corpus and solution not mutually exclusive (#3029)
* make fuzzer great again

* crash handlers

* hello from windows

* fk

* gee

* m

* temporary fix

* f

* mm

* CICI

* fixer

* Fix Dockerfile

* lol

* clp

* Fuck you clippy

* This lint makes no sense, 0

* ??

* a

* fix

* this lint makes 0 sense

* mm

* clp

* a

* a

* clp

* clippy

* clp

* mm

* FMT

* p

---------

Co-authored-by: Your Name <you@example.com>
Co-authored-by: toka <toka@tokas-MacBook-Air.local>
2025-03-05 20:10:04 +01:00
Romain Malmain
e864bc28b1
Abort on triple fault for in process executors, refactor AddressFilter and PageFilter (#3026)
* abort on triple fault in generic inprocess signal handler

* refactor qemu filters

---------

Co-authored-by: Toka <tokazerkje@outlook.com>
2025-02-28 15:44:22 +01:00
60be7f97ac calculate wcrt bounds 2025-02-28 11:23:36 +01:00
108d5dfe77 benchmark split 2025-02-27 18:47:33 +01:00
c3d45680e8 config+bounds update 2025-02-27 17:10:18 +01:00
Dominik Maier
ce5fd435ea
Move all unnecessary std uses to core,alloc (#3027)
* Move all unnecessary std uses to core,alloc

* More

* more fix

* more

* more

* Remove libafl-fuzz grimoire

* more

* more

* more cleanup

* remove bins

* fix

* more fix
2025-02-27 14:32:37 +01:00
Dominik Maier
c7207dceb0
Rust 2024 edition (#3022)
* Rust 2024 edition

* gen = generalized

* Fixes

* more fix

* More fix

* even more fix

* fix libfuzzer

* ignore clippy lint

* even more

* fix docs?

* more?

* More pub more better

* win

* docs

* more

* More

* doc stuff?

* counter_maps->counters_maps

* libafl qemu fixes for rust 2024

* fix?

* fmt

* unsafe lint

* final fixes

* fmt

* working?

* not working

* unused import

* win?

* update libafl qemu hash

* fmt

* fix

* unused imports

* fix

* fix

* more foix

* less edition

* fix

---------

Co-authored-by: Romain Malmain <romain.malmain@pm.me>
2025-02-27 00:12:29 +01:00
6a4d1af606 swap set48, 64 2025-02-26 14:27:54 +01:00
d2aaf0bf6e config++ 2025-02-26 12:22:52 +01:00
98ed400e1a config updates 2025-02-26 12:17:59 +01:00
fd336e8ab0 fix wrong minia 2025-02-26 10:52:59 +01:00
56c046ecf6 better handling for indices 2025-02-25 13:53:53 +01:00
cb20424cec keep worst observed case, precise isns -> time calculation 2025-02-24 18:35:53 +01:00
Dominik Maier
e5ba51aae4
More LibAFL_QEMU Launcher things (#3000)
* More LibAFL_QEMU Launcher things

* Fix CI

---------

Co-authored-by: Dongjia "toka" Zhang <tokazerkje@outlook.com>
2025-02-24 16:12:37 +01:00
63f6f02ba9 snakefile clean 2025-02-21 19:30:18 +01:00
1df4bba604 config updates 2025-02-21 18:36:32 +01:00
800f2c8788 feedback for job woet 2025-02-21 18:29:44 +01:00
Celian G.
40c0a8c57c
Improved calling convention support for x86, x86_64, arm and aarch64 for libafl-qemu (#3013)
* Improved calling convention support for x86, x86_64, arm and aarch64

* fix

* fix write_function_arguments

* fix argument_error

* follow clippy advice

* last change?

* fix guestaddr issue

* add code block for cargo-fmt

* default to default convention

* fix mistake

* add pub

* fix

* changes after review

* last change?

---------

Co-authored-by: celian <cglenaz>
2025-02-21 18:04:45 +01:00
ca8d9fdf0a abb woet increases are interesting 2025-02-21 14:24:34 +01:00
Dominik Maier
7c83be2408
Add auto format to settings.json.default, format documentation and macros (#3019)
* Add auto format to settings.json.default

* Add more nightly rustfmt features
2025-02-21 13:31:31 +01:00
66e299cfce intermediat snapshots _at_xh 2025-02-21 10:13:47 +01:00
6d1d7482ee ensure fuzz-length u32 2025-02-21 10:13:07 +01:00
Valentin Huber
1eef4ffb58
Introduce ListInput (#2972)
* Introduce ListInput

* Add remove mutators for ListInput

* Merge ListInput and MultipartInput

* Reimplement MultipartInput as a special case of ListInput

* Revert changes to Cargo.toml

* Add collection of generic listinput mutators

* Fix example

* Add note to MIGRATION

* Split list and multi into separate modules

* Fix docs

* Using string names again in the multi example fuzzer

* Remove unnecessary code

* Fix fuzzer

* Use key instead of name for MultipartInput key

* Prettier code in example fuzzer

* Do not convert slice to vec manually
2025-02-20 13:41:53 +01:00
Dongjia "toka" Zhang
9f28672ea1
Fix ReplayStage (#3007) 2025-02-19 18:06:49 +01:00
Dongjia "toka" Zhang
61568a9be1
Restartable trait (#3004)
* separate into Restartable

* typo

* fixes, blanket impl

* aa

* lol

* aa

* fixer

* lol
2025-02-19 15:06:31 +01:00
dae46ea26b enable fallback interrupt randomization 2025-02-19 12:32:01 +01:00