3180 Commits

Author SHA1 Message Date
a18a5f9bcf fix everything interesting 2024-08-26 15:10:12 +02:00
Aarnav
07db74b416
Libafl-fuzz: introduce unicorn mode (#2499)
* libafl-fuzz: introduce unicorn mode

* taplo format

* libafl-fuzz: fix qemumode

* taplo format
2024-08-26 11:32:44 +02:00
Marco C.
a388012429
Do not use caret requirements (#2498) 2024-08-24 00:02:37 -05:00
Romain Malmain
1f55458293
Fix fmt & remaining md links (#2497) 2024-08-22 19:08:44 -05:00
Alexander Qi
0018f7e406
bolts: Support dump_registers on Windows/x86 and Windows/aarch64 and fix sig_ign on Windows/x86 (#2494)
* bolts: Support dump_registers on Windows/x86

* bolts: Support dump_registers on Windows/aarch64

* bolts: Fix sig_ign() on Windows/x86

* bolts: Fix format of dump_registers under Windows

* bolts: Add test for dump_register under Windows
2024-08-22 18:22:24 -05:00
Marco Grassi
1dfd225b1b
Fix fuzzer links in the libafl book (#2493)
* the rustup official command to update is 'rustup update' not 'rustup upgrade', although to catch mistakes, 'rustup upgrade' also fallback to update

* fix references to baby_fuzzer and baby_fuzzer new location

* modernize a bit the manifests and code snippets for the baby_fuzzer to make the experience more consistent with the current rust compiler

* fix another reference path for baby fuzzers

* fix frida fuzzers locations in the book

* fix the concolic hybrid fuzzers location in the book

* fix baby_no_std location in the book

* fix nyx fuzzers location in the book

* Revert "modernize a bit the manifests and code snippets for the baby_fuzzer to make the experience more consistent with the current rust compiler"

This reverts commit c58bfbfffd06a3afa8338043dde6ed59b03d8178.
2024-08-22 18:15:36 -05:00
Romain Malmain
8d0ad23856
Check markdown links validity in CI (#2495)
* add markdown link check in ci

* fix broken links when possible.
configuration file for md checker.

* accept code 200...

* more fixes

* more fixes

* more fixes
2024-08-22 18:15:15 -05:00
Dongjia "toka" Zhang
f856092f3d
Fix libxml2 on fuzzbench (#2492)
* fix

* fmt

* fuck

* from windows

* fix

---------

Co-authored-by: Your Name <you@example.com>
2024-08-21 16:41:18 +02:00
Romain Malmain
4b87d7f4eb
Custom QEMU emulator typed builder + ExitHandler / Commands refactoring (#2486)
* Add a custom typed builder for Emulator

* Unify qemu_init for usermode and systemmode

* Remove env from qemu init args (it is unused in QEMU in practice)

* expose thread hooks to systemmode

* rename qemu_config to config

* Replace ExitHandler by EmulatorDriver

* Reorder generics alphabetically for Qemu{,Fork}Executor

* Moved snapshot manager to Emulator to continue centralizing mains objects in the same structure

* Reimplementation of CommandManager working with enums instead of tables

* Macro has been adapted to do this work automatically

* Moved snapshot stuff to dedicated module

* Removed many Rc<RefCell<...>>, now useless with the removal of vtables

* Builder given by Emulator via `Emulator::builder`. Reduced trait bound overhead
2024-08-21 16:36:45 +02:00
Marco Grassi
16aa218457
Fix rustup command in the LibAFL book (#2491) 2024-08-20 22:49:32 -05:00
bd7ddaffbd fix releases 2024-08-20 12:20:55 +02:00
6995cd053b fix snakefile 2024-08-19 16:28:11 +02:00
e9fb73e65b WIP: per-task response times 2024-08-19 16:08:45 +02:00
Dongjia "toka" Zhang
eb3dff07b6
Add more missing ngram8 cfgs (#2490)
* fix dump cfg

* add missing cfg

* more

* taplo fmt
2024-08-19 14:39:21 +02:00
Dongjia "toka" Zhang
7a5c695401
Add missing ngram8 cfg (#2489)
* fix dump cfg

* add missing cfg
2024-08-19 14:23:47 +02:00
bf7ad374a0 stupid bug fix
stupid bug fix
2024-08-19 10:22:31 +02:00
de9c0a6d1e WIP: input snippet mutation 2024-08-16 09:58:21 +02:00
Addison Crump
f3433767be
Make pcs_init compatible with multiple DSOs (#2488)
* make pcs_init compatible with multiple DSOs

* clippy
2024-08-15 15:56:41 +02:00
3b6cd3bc45 fix bug causing skipped mutation when part size is 0 2024-08-15 09:38:52 +02:00
Marco C.
21051dc26f
qemu: Add QemuConfig to set qemu args via a struct (#2339)
* Add QemuConfig to set qemu args via a struct

* Add derive macro to automate the qemu string args generation

* fix tests
2024-08-14 15:30:14 +02:00
Romain Malmain
6979032ad9
Qemu generics cleanup (#2484)
* cleanup generics

* remove most extern C

* update qemu to latest revision

* executor trait bounds minimization
2024-08-14 12:55:43 +02:00
72f9de45d0 fix cargo.toml 2024-08-14 09:41:02 +02:00
46aa6cec0f reads behind config flag 2024-08-14 09:10:30 +02:00
b9f0151e87 repeat interrupt mutations 2024-08-14 08:55:23 +02:00
712ac137d7 logging and reporting 2024-08-14 08:50:34 +02:00
920a996d95 multipart seed reading 2024-08-14 08:42:33 +02:00
Romain Malmain
13ba32ed2a
Unify qemu executor (#2483)
* Remove stateless qemu executor

* All harnesses take a reference to an emulator as parameter now

* harness takes an emulator as first parameter, and input as second parameter (opposite of previous definition)

* bump libafl qemu dependencies to the latest version
2024-08-13 19:44:10 +02:00
Romain Malmain
00806b177d
Qemu native hooks refactoring (#2480)
* qemu native hooks refactoring (companion patch of qemu-libafl-bridge#82)

* update stubs
2024-08-13 18:40:51 +02:00
Aarnav
2287afc59b
libafl-fuzz: Introduce Support for QEMU mode (#2481)
* libafl-fuzz: simplify Makefile.toml

* Re-introduce support for old AFL++ forkserver

* clippy

* libafl-fuzz: add support for QEMU mode

* libafl-fuzz: simplify Makefile
2024-08-13 07:13:59 -05:00
3db17ceb98 WIP: store memory reads 2024-08-12 15:31:56 +02:00
05c17d3159 report state space exporation 2024-08-12 12:07:31 +02:00
Niklas Gögge
799c634fef
Implement FeedbackFactory for {Const,Not}Feedback (#2478)
* libafl: Impl FeedbackFactory for NotFeedback

* libafl: Impl FeedbackFactory for ConstFeedback
2024-08-09 12:24:46 +02:00
Dongjia "toka" Zhang
9b32f85124
Fix dump cfg pass (#2476) 2024-08-06 18:47:49 +02:00
Romain Malmain
723f4a1cb0
Fix various QEMU bugs (#2475)
* Update LibAFL QEMU to the latest version (V9.0.2 update, important bug fixes, ... - check the dedicated repo for more info)
* fix bug in hook execution, causing first execution hooks to be run multiple times.
2024-08-05 23:48:35 +02:00
Max Ammann
3bebbe0dac
Update AsanBacktrace documentation (#2377)
* Add AsanBacktrace documentation

* Update stacktrace.rs
2024-08-05 22:10:46 +02:00
Aarnav
949a25a29a
It's frida time for libafl-fuzz (#2469)
* libafl-fuzz: misc nit in check_autoresume

* libafl-fuzz: add FRIDA mode

* libafl-fuzz: improve Makefile

* libafl-fuzz: fix Ci

* libafl-fuzz: clang-format test-cmpcov.c

* libafl-fuzz: no cmplog for persistent frida

* libafl-fuzz: minor CI fix

* libafl-fuzz: fix frida persistent mode

* libafl-fuzz: add frida seeds

* misc: typo
2024-08-05 18:10:45 +02:00
f8d9363e7e update snakefile 2024-08-04 09:46:39 +02:00
ade004cffb update targets 2024-08-04 09:40:53 +02:00
David CARLIER
291fdeb85e
bolts: fix openbsd build (#2467)
Co-authored-by: dcarlier <dcarlier@openbsdvbox.chello.ie>
2024-08-01 08:14:09 +02:00
Addison Crump
7ee5962288
remove libfuzzer-best recommendation (#2466) 2024-07-31 17:08:34 +02:00
Aarnav
6d4f071eaa
Misc libafl-fuzz improvements (#2463)
* libafl-fuzz: ignore seeds that are not regular files

* libafl-fuzz: remove 4 dict files limit

* libafl-fuzz: clippy

* libafl-fuzz: add -t option

* libafl-fuzz: fix typo in seed feedback
2024-07-31 14:54:11 +02:00
Dominik Maier
8fb80c3f3a
libafl_qemu: Continue build with outdated LLVM, ignore TUI race conditions (#2461)
* libafl_qemu: Continue build with outdated LLVM

* Ignore race condition

* ignore more race conditions, remove useless clones

* fix fixes
2024-07-30 14:48:17 +02:00
Romain Malmain
c319fe2033
Cheap reader for bytes slice (#2261)
* initial draft implementation

* change name to follow rust convention.

* revert use of HasTargetBytes instead of HasMutatorBytes for BytesSubInputMut

* clippy

* nostd

* clippy

* clippy

* * HasLen required if implementing HasTargetBytes.
* Added a checked version of the read to slice.

* clippy

* fix name.
better doc.

* added a common bytes trait for HasTargetBytes and HasMutatorBytes.

* change interface

* fix tests

* clippers

* use byte slice for subbytes

* adapt to main

* fix doc

* mut sub slice version. return subinput to old state, and add subslice stubs

* better api, doc fixes.

* Don't clone, reshuffle

* Move and rename

* Uh-oh

* move to bolts. rename things.

* nostd

* format

* alloc

* fix doc

---------

Co-authored-by: Dominik Maier <domenukk@gmail.com>
Co-authored-by: Dominik Maier <dmnk@google.com>
2024-07-30 13:46:40 +02:00
Dominik Maier
211809dddb
Cmplog bytes without alloc (#2442)
* Cmplog bytes without alloc

* fixes

* clippy

* remove wrong %
2024-07-30 13:42:48 +02:00
Dominik Maier
c4c0fb6750
Update pyo3 (#2459)
* Update pyo3

* Update pyo3 to 0.22

* Fix qemu python

* clippy

* fmt

* nautilus python

* More pyo3

* Make signature more legible
2024-07-29 22:55:28 +02:00
Dominik Maier
651ea027b9
Speedup CI by moving checkout back (#2457)
* Speedup CI by moving checkout back

* apparently not legal

* better?
2024-07-29 17:48:46 +02:00
Aarnav
a863720320
libafl-fuzz: Increase cmplog CI timeout (#2458)
* libafl-fuzz: increase cmplog CI test timeout

* libafl-fuzz: fix cmplog CI
2024-07-29 17:39:34 +02:00
Aarnav
e55cbee107
libafl-fuzz: Fix invalid short param for input_ext (#2456) 2024-07-29 16:33:46 +02:00
Dominik Maier
75af67f1e0
Fix CI after Rust 1.80, update to Ubuntu 24.04 (#2449)
* 0.13.2 (for real this time)

* More 0.13.2

* Make sure this never bites us

* Update ahash

* Fix CI after rust 1.80

* Does 18 work?

* Trying to fix this?

* lol regex

* noble

* works?

* fix llvm-config

* fmt

* Windows?

* more fix?

* more fix

* remove pip

* Add find_python3_version support to libafl_cc

* llvm-config

* more curl

* windows has no apt lol

* more
2024-07-29 15:31:41 +02:00
David CARLIER
bab50f23c5
bolts: fix build warning with missing doc comment for haiku (#2455) 2024-07-28 22:21:06 +02:00