3198 Commits

Author SHA1 Message Date
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
Dominik Maier
6df1b34375
Add Taplo check to CI (#2451)
* Add Taplo check to CI

* more taplo

* Try to make this easier
2024-07-26 18:38:50 +02:00
kvalerio
09a8b1dd80
Revive dead link 🧟 (#2452)
* dead link

* deadlink
2024-07-26 18:37:44 +02:00
Dominik Maier
e83dc792da
0.13.2 (for real this time) (#2448)
* 0.13.2 (for real this time)

* More 0.13.2

* Make sure this never bites us

* Update ahash
2024-07-26 13:41:05 +02:00
Mrmaxmeier
afbdc02c54
Format all tomls with taplo fmt (#2436)
Co-authored-by: Dominik Maier <domenukk@gmail.com>
2024-07-26 10:03:10 +02:00
Aarnav
76e1b4cb1e
Fix cmplog implementation (#2439)
* fix cmplog implementation
only set testcase filepath if filepath is none

* libafl-fuzz: fix minor CI

* add missing fields to AFLppCmpLogOperands

* libafl-fuzz: pin CI AFL version to a commit
fix extended_cmplog_instrumentation

* libafl-fuzz: fix CI

* this should not panic

* aaa

* libafl-fuzz: fix cmplog CI

---------

Co-authored-by: Toka <tokazerkje@outlook.com>
2024-07-25 18:10:21 +02:00
Saketh Reddy
c857b8dd77
Fix markdown issue in fuzzers/libpng/libfuzzer_libpng_cmin/README.md (#2437)
Adds a single `
2024-07-23 16:45:58 +02:00
Dongjia "toka" Zhang
7391c6040b
always update textcase.file_path (#2432) 2024-07-23 15:02:03 +02:00
Mrmaxmeier
c44d361828
CI: Update actions and fix warnings (#2435)
* CI: update to checkout@v4 action

Not sure why they decided to bump a major version. It seems like this is
unnecessary churn: https://github.com/actions/checkout/pull/1436#issuecomment-1737711301

* CI: replace archived `actions-rs/toolchain`

It's been unmaintained for four years and has been throwing warnings in
CI:

> The `set-output` command is deprecated and will be disabled soon.

* CI: Bump `cargo-install` action.

This should fix the remaining warnings in CI?

* CI: mdbook-linkcheck: workaround for build error
2024-07-23 12:44:34 +02:00
Zofyan
0dc94a48c5
Added implementation of tolower in libqasan (based on BIONIC's implementation). This is to make LibAFL more compiler agnostic as this function can be named differently sometimes. (#2421)
Co-authored-by: Sofyan Aarrass <s.aarrass@secura.com>
2024-07-22 15:45:32 +02:00
Niklas Gögge
0999ac5003
libqasan: Add missing return to qasan_swap (#2416) 2024-07-22 15:45:13 +02:00
Aarnav
e6b94f3715
Feature/libafl fuzz misc (#2430)
* libafl-fuzz: add cmplog to CI
libafl-fuzz: add option to specify custom rng sed
libafl-fuzz: add help messages to CLI, add file extension support
libafl-fuzz: adhere to AFL++ cmplog bin path format
libafl-fuzz: avoid races when writing to fuzzer_stats
libafl-fuzz: add time tracking for CalibrationStage, MutationalStage and SyncFromDiskStage

* libafl-fuzz: fix libafl paths

* libafl-fuzz: remove redundant cmplog check

* libafl-fuzz: ingore UnstableMapEntries when using queue scheduler in afl_stats.rs
libafl-fuzz: track max_depth for QueueScheduler
libafl-fuzz: fix custom input file

* libafl-fuzz: fix Makefile

* clippy
2024-07-22 15:43:47 +02:00
s1341
695184169e
frida: make hooks thread local (#2429)
* frida: make hooks thread local

* Fmt

* clippy
2024-07-22 14:09:08 +02:00
Dongjia "toka" Zhang
f6151f4507
0.13.2 (#2423)
* 0132

* fix
2024-07-19 23:00:37 +02:00
Romain Malmain
82f11c22ad
Various CI improvements + fix wrong format check in CI (#2417)
use of LLVM 19 by default
    LLVM version should be much easier to switch from now on
    a lot of code repetition has been deleted
    removed llvm-related github action
    fix format check
    other small things

---------

Co-authored-by: Toka <tokazerkje@outlook.com>
2024-07-19 22:32:50 +02:00
Scott
747385ae7d
update function from _libafl_exit_call2 to _libafl_sync_exit_call2 (#2392)
Co-authored-by: Scott Powell <scottmpowell@protonmail.com>
2024-07-19 19:01:54 +02:00
Romain Malmain
1205c2144c
Restructure the fuzzers folder (#2409)
* move fuzzers in subfolders

* add readme

* remove redundent fuzzers
2024-07-19 18:24:24 +02:00
Aarnav
c22a62c32a
libafl-fuzz: add IndexesLenMinTimeScheduler back (#2426) 2024-07-18 16:47:00 +02:00
Dongjia "toka" Zhang
78a30c4403
Fix baby fuzzer tui (#2425) 2024-07-18 14:56:21 +02:00
Dongjia "toka" Zhang
56d70accf5
Fix cmin (#2420)
* fix minimizer

* clp
2024-07-18 11:11:37 +02:00
Dongjia "toka" Zhang
4f970baa7b
Change Corpus Pruning algorithm (#2418)
* push

* upd

* add last found time

* add common as prerequisite

* clp

* aa

* more clp

* fix how to get corpus id

* pruning

* aa

* no std

* fix

* working?

* push
2024-07-18 11:11:14 +02:00
Dongjia "toka" Zhang
536f00a056
Don't panic even if bitmap is zero in calibrate.rs (#2419) 2024-07-17 18:26:17 +02:00
Romain Malmain
c96ea616fe
Qemu helpers & hooks refactoring (#2267)
* Helper is now called Module.

* Emulator now contains hooks state.

* Emulator is managed by QemuExecutor.

* QEMU hooks have been completely refactored on the rust side.

* Generics cleanup.
2024-07-17 11:46:42 +02:00
Axel Souchet
f5e47c33fb
Documentation fix in 'Design' > 'Architecture'. (#2412) 2024-07-17 11:08:29 +02:00
Aarnav
b9da7dd87f
Introduce Persistent Record for libafl-fuzz (#2411)
* libafl-fuzz: fix PERSISTENT_SIG and DEFERRED_SIG

* libafl-fuzz: add AFL_PERSISTENT_RECORD

* libafl-fuzz: update README
2024-07-17 00:35:06 +02:00
Dominik Maier
713652e5d8
Better errors for empty registry in AnyMap (#2405)
* Better errors for empty registry

* Make errors non-panic

* clippy
2024-07-16 18:10:18 +02:00
Dongjia "toka" Zhang
f00470ddaa
Corpus pruning stage (#2399)
* push

* upd

* add last found time

* add common as prerequisite

* clp

* aa

* more clp

* fix how to get corpus id

* pruning

* aa

* no std

* fix
2024-07-16 18:04:23 +02:00
__gsch
d8e53d5b65
impl HasEventManagerId for LlmpRestartingEventManager (#2406) 2024-07-16 14:06:56 +02:00
Aarnav
791598228e
fix incorrect interval check in sync from disk stage (#2408)
* fix incorrect interval check in sync from disk stage

* simplify check
2024-07-16 13:52:25 +02:00
Dongjia "toka" Zhang
074a16f844
Fix autotokens (#2407) 2024-07-16 13:04:24 +02:00
Dominik Maier
4370a84bd2
Expose find_new_files_rec in libafl_bolts::fs (#2404) 2024-07-16 04:47:03 +02:00
Dominik Maier
dc93f6c186
Rename load_new_from_drectory to find_new_files_rec (#2403) 2024-07-16 03:35:36 +02:00
Dominik Maier
7850b9bce6
Address recursion Clippy in sync.rs (#2402) 2024-07-16 03:26:45 +02:00