David CARLIER
1cf3df665a
Switch MiniBSOD to mach crate for Apple ( #2162 )
2024-05-12 18:37:11 +02:00
Kevin Phoenix
3328f06de4
Add qemu runtime defs for aarch64 ( #2151 )
2024-05-12 15:39:55 +02:00
Langston Barrett
f17a45dcc3
bolts: Fix feature name in assert (serde{,any}_autoreg
) ( #2160 )
2024-05-12 13:20:03 +02:00
Dongjia "toka" Zhang
7c9ac6d4b5
Revert "Adding ExitCodeObserver and ExitSignalObserver ( #2138 )" ( #2157 )
...
This reverts commit ee7dafae4100397698e5266465919bfdbc40af51.
2024-05-08 15:26:07 +02:00
Valentin Huber
ee7dafae41
Adding ExitCodeObserver and ExitSignalObserver ( #2138 )
...
* Adding ExitCodeObserver and ExitStatusObserver
* Introducing ExitKind::Interrupted
2024-05-08 15:17:24 +02:00
Addison Crump
614b149cae
Fix cfg uses across codebase ( #2154 )
...
* start fixup of cfgs
* whoops
* remaining issues
* maybe fixup macos
* apparently that is ios code?
* fix no_std
* Re-enable tcp_compression
* fix tcp broker
* remove tcp_debug flag
* fmt
* clippy
* less unwrap while we're at it
* doc
* add back pub star uses for libafl_qemu
---------
Co-authored-by: Dominik Maier <dmnk@google.com>
2024-05-08 14:31:10 +02:00
Max Ammann
f6d2eaacb4
Fix libafl_libfuzzer's compatibility with LLVM 14 ( #2136 )
...
* Always use Rust's nm instead of host system one
* Fix formatting
* Fix formatting
2024-05-08 13:53:12 +02:00
ba3850cf4d
remove stg feedback from systemstate flag
2024-05-08 12:49:40 +02:00
3f9a2ed6c0
trace executed abbs, instead of states
2024-05-08 12:30:10 +02:00
David CARLIER
695efeab42
bolts: Fix minibsod build on apple ( #2155 )
2024-05-08 05:31:13 +02:00
Dominik Maier
c97c8cf83e
Rename Handler -> Handled, various other cleanups after #2142 ( #2152 )
...
* Handle name cleanup after #2142
* Handleable -> CanBeHandled
* CanBeHandled -> Handled
* clippy
* forgot one
* Handled more
2024-05-07 19:23:13 +02:00
Addison Crump
c1a55982b6
Stable type_eq ( #2150 )
...
* stable type eq
* whoops, wrong section
* satiate clippy
* remove extraneous comment
* explain
* bonus inline
2024-05-07 17:09:15 +02:00
Dongjia "toka" Zhang
e7e820868c
Change special exitcode from 137 to 9 in simple.rs too ( #2153 )
2024-05-07 14:31:19 +02:00
Romain Malmain
bed500471a
QEMU generic memory iterator ( #2148 )
...
* QEMU generic memory iterator + Refactoring
* Generic Memory Iterator (systemmode only for now): It is now possible to iterator over memory ranges, independently of the address kind
* Refactoring or Emulator / Qemu structures: they are now handled separately in different files
* Refactoring of Exit Handlers: Result / Error structs have been clarified
* Simple handler for signals
* add new `check-cfg` calls for libafl qemu
2024-05-07 10:46:15 +02:00
cube0x8
a16fb88f3e
Add null ptr to devices vec (QEMU systemmode) ( #2141 )
2024-05-06 23:19:30 +02:00
88c5c8a19f
feedback for aggregated traces
2024-05-06 16:00:11 +02:00
Dongjia "toka" Zhang
4562f19bdc
Qemu ctrl c exit ( #2147 )
...
* fix
* ignore
* fix
* aaa
* bbb
2024-05-06 15:42:43 +02:00
0393f18a47
add stg edge feedback
2024-05-06 14:46:35 +02:00
Dongjia "toka" Zhang
b0d592dc3a
Add to how to leave tui screen ( #2146 )
2024-05-05 17:21:15 +02:00
Dongjia "toka" Zhang
d4ff7b86b1
Add windows test & ci & fix ( #2144 )
...
* fix
* ignore
* fmt
* a
2024-05-05 14:53:27 +02:00
Dongjia "toka" Zhang
502929d967
Separate map observers ( #2143 )
...
* rename
* rename
* fmt
* fix
* fmt
* separate observers
* doc fx
2024-05-04 23:11:00 +02:00
Dongjia "toka" Zhang
b0ac25a7b5
Rename Reference to Handle ( #2142 )
...
* rename
* rename
* fmt
* fix
* fmt
2024-05-04 18:16:28 +02:00
Dongjia "toka" Zhang
41ff7438eb
Fix incrementing found_objective( #2139 )
2024-05-03 23:30:14 +02:00
Langston Barrett
382673b173
GenStage
: A stage for generational (e.g., black-box) fuzzers (#2137 )
...
* GenStage: A stage for generational (e.g., black-box) fuzzers
* mv stages/{gen,generation}.rs
* Fix doc link
* `GenStage`: Alphabetize type parameters
* Fighting rustdoc
2024-05-03 19:18:14 +02:00
Dongjia "toka" Zhang
f75c5ff4d3
Add found_objectives
metadata ( #2093 )
...
* try
* add stuff
* clp
* Move to counter, remove penalization
* fix
* even milder
* fix
* clp
* no score
---------
Co-authored-by: Dominik Maier <dmnk@google.com>
2024-05-03 16:37:05 +02:00
3453d02b1d
fix fuzzing loop returning nothing
2024-05-03 13:28:49 +02:00
d93ed809f1
improve stg parsing
2024-05-03 13:28:15 +02:00
Valentin Huber
7fe0c576db
Make CommandExecutor Generic on the specific Input ( #2129 )
2024-05-02 15:39:06 -04:00
Dongjia "toka" Zhang
2e81dc6c59
Fix DDFuzz instrumentation ( #2134 )
2024-05-02 20:00:51 +02:00
Romain Malmain
02ef0c4dda
fix qemu systemmode fuzzers exit code ( #2133 )
2024-05-02 16:27:07 +02:00
Stefan Zabka
ec944a0ea4
Allow setting stdout_file in non-fork launcher ( #2127 )
...
* fix(launcher.rs): hide file output behind appropriate feature flag
discovered while debugging #2111
* fix(launcher.rs): implement stdout/stderr piping for non-forking unix
* hide all accesses to stdout_file in cfg blocks
* Conditionally add stdout_file config in frida_gdiplus
2024-05-02 10:24:36 -04:00
Romain Malmain
2302f1b35c
Fix QEMU doc not building (again) ( #2130 )
...
* fix doc not building.
2024-05-02 15:17:35 +02:00
Dongjia "toka" Zhang
359e94ec97
ctrl c handler fix for non-fork mode ( #2132 )
...
* poc
* ai suggestion
* rename this
* aaaa
* fmt
* simplify
* delete blob
* ignore
* fixup?
* some progress on cow-ification
* some more
* clippy fixes, finalise tests
* whoops, missed a spot
* no std compat
* api change: Named now requires alloc feature
* doc fix
* missed a spot
* additional fixes
* libfuzzer fixes
* fix tutorial
* fix
* add
* aa
* fix tutorial
* fix
* Rename
* fix
* aa
* fmt
* aa
* aa
* another closure
* clp
* fix stuff
* fix non fork
* fmt
---------
Co-authored-by: Addison Crump <addison.crump@cispa.de>
2024-05-02 14:43:25 +02:00
cube0x8
c79cdc89ac
add mmap hooks to libqasan ( #2122 )
...
* add mmap hooks to libqasan
---------
Co-authored-by: Romain Malmain <romain.malmain@pm.me>
2024-05-02 10:39:33 +02:00
Romain Malmain
935100e7a7
Qemu update to latest version + various fixes ( #2119 )
...
* Fix maps iterator
* Added paranoid debug feature.
* Fix snapshot bugs.
* Update qemu-libafl-bridge.
* Added auto-generation of `x86_64_stub_bindings.rs` .
* Fix sync_exit calling to stopped CPU.
2024-05-02 09:31:54 +02:00
Dongjia "toka" Zhang
2f7c19e2b1
Change centralized launcher signature ( #2094 )
...
* poc
* ai suggestion
* rename this
* aaaa
* fmt
* simplify
* delete blob
* ignore
* fixup?
* some progress on cow-ification
* some more
* clippy fixes, finalise tests
* whoops, missed a spot
* no std compat
* api change: Named now requires alloc feature
* doc fix
* missed a spot
* additional fixes
* libfuzzer fixes
* fix tutorial
* fix
* add
* aa
* fix tutorial
* fix
* Rename
* fix
* aa
* fmt
* aa
* aa
* another closure
* clp
* fix stuff
---------
Co-authored-by: Addison Crump <addison.crump@cispa.de>
2024-04-30 19:44:57 +02:00
Dongjia "toka" Zhang
b23180394b
Fix Ctrl-C Handler ( #2124 )
...
* fix
* fix
* win
* win clp
* a
* FMT
* aaaaaaaaaaa
* aa
---------
Co-authored-by: Your Name <you@example.com>
2024-04-30 17:18:39 +02:00
clesmian
61ac4ea7be
Improve OnDiskTOMLMonitor
( #2125 )
...
* Allow for more frequent updates of TOML monitor
* Don't skip first client
* Reduce code duplication
* Immediately write first TOML file
* Rust fmt
* Use same client numbering as other monitors
* Fmt
2024-04-30 09:05:33 -04:00
Gregory Petrosyan
b49ab999e3
libafl_bolts: rands
super mega ultra giga house cleaning of doom ( #2123 )
...
* rands: simpler rand_trait code, remove useless test
* rands: provide and use proper random_seed()
* rands: add missing golden tests
* Don't use current_nanos() for seeding
* rands: remove RandomSeed trait
2024-04-29 11:00:44 -04:00
Dongjia "toka" Zhang
50f14d44fa
Restrict more on edges map API ( #2117 )
...
* fix
* fix
* feature guard
* use
* cannnot find
* fmt
* more
* fix
* fix
* more
* fucking fmt just shut
* rename and change stuff
* fix
* fix
* fixxxxxxxxxx
2024-04-29 16:28:40 +02:00
Langston Barrett
b0248461e2
Allow for AsIter(Mut)/AsSlice(Mut) to be implemented in safe Rust ( #2120 )
...
* Generalize `AsIter` to allow iterating over contents of a `RefCell`
Towards `MapObserver`s in safe Rust.
* Helpers for `RefCellValueObserver`
* MapObserver: Return owned Self::Entry from .get()
`Self::Entry` is `Copy`, so there's not much value in returning a
reference from `get()`. Futhermore, returning a reference limits the
possible implementations of `MapObserver`, because it forces the
borrow/reset to outlive the body of the method.
* MapObserver: Replace `.get_mut()` with `.set(idx, val)`
Like the previous commit, this is intended to expand the possible
implementations of `MapObserver` to types with interior mutability,
which can't necessarily loan out their content.
* Make `RefCellValueObserver` into a safe `MapObserver`
* as iter mut
* as slice (mut): allow for non-& refs
* nostd
* CI round 1
* cleanup + AsSlice defs for RefCellValueObserver
* clippy fixes
* avoid unnecessary imports
* whoops, too aggressive
* use deref instead of as slice
* whoops
* fix as slice conditional importing in stable
---------
Co-authored-by: Addison Crump <addison.crump@cispa.de>
2024-04-27 18:36:56 +02:00
Addison Crump
28c43b332f
Match by Ref fix ( #2105 )
...
* match by ref fix
* impl Named for Reference
* rename
* magic indexing
* whoops
* docs, clippy
* some additional CI complaints
* other libafl_qemu fixes
* missed an alloc feature
* a smattering of fixes
* use from not direct construction
* tinyinst fix
* horrible double-mutability things
* fixup nyx
* from not new
* forkserver_simple fixes
* dogfood: forkserver
* mmmm yummy dogfood
* round one CI fixes
* clippy appeasement
* deref generic impl to simplify usage
* adaptive serialization (ouch)
* remaining clippy items
* I am tired
* new not with
* fixup: aflpp tracing was not actually constructable
* fix tmin
* reduce complexity of map feedback now that we do not need to constrain
* frida fixes
* fix concolic
* type_ref => reference
2024-04-27 18:08:09 +02:00
Dongjia "toka" Zhang
084b9b5878
Batch timeout fix ( #2109 )
...
* fix
* FMT
* unused
2024-04-26 17:10:36 +02:00
Aarnav
32963be453
add crash_exitcode to Forkserver to accomodate AFL_CRASH_EXITCODE ( #2107 )
...
* add crash_exitcode to Forkserver to accomodate AFL_CRASH_EXITCODE
* make crash_exitcode i8
---------
Co-authored-by: aarnav <aarnav@srlabs.de>
2024-04-26 16:24:25 +02:00
Addison Crump
c2e0e8ddbe
Add recv_blocking_with_flags ( #2102 )
...
* add recv_blocking_with_flags
* rollback, whoops
2024-04-26 16:22:32 +02:00
Dongjia "toka" Zhang
abcb2bf33e
Remove jobs dependency in CI ( #2108 )
2024-04-25 16:07:38 +02:00
Addison Crump
4c95d9029a
Split android and ios tests ( #2106 )
...
* split android and ios tests
* whoops
2024-04-25 12:23:46 +02:00
Romain Malmain
dd0fbff819
Small refactoring of libafl_qemu structure ( #2098 )
...
* Architecture-specific stuff is now in the `arch` directory
* Helpers are now in the `helpers` directory
* `emu.rs` has been moved as `emu/mod.rs` for consistency with the rest of the repository
2024-04-24 21:47:29 +02:00
Dongjia "toka" Zhang
c622a28eba
Rename from ReReference to Reference ( #2099 )
2024-04-24 15:06:33 +02:00
Gregory Petrosyan
1e8667a9f9
libafl_bolts: more rands
improvements ( #2096 )
...
* rands: add missing inline directives
See:
- https://nnethercote.github.io/perf-book/inlining.html
- https://users.rust-lang.org/t/enable-cross-crate-inlining-without-suggesting-inlining/55004/6
* rands: better fast_bound() signature
2024-04-24 14:01:37 +02:00