mirror of
https://github.com/tursodatabase/limbo.git
synced 2025-07-07 12:35:00 +00:00
feat: add guide on fuzing
This commit is contained in:
parent
0013c93fa5
commit
2e79de3466
2 changed files with 49 additions and 6 deletions
12
fuzz/Cargo.lock
generated
12
fuzz/Cargo.lock
generated
|
@ -643,7 +643,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_core"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"built",
|
||||
"cfg_block",
|
||||
|
@ -680,7 +680,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_ext"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"chrono",
|
||||
"getrandom 0.3.1",
|
||||
|
@ -689,7 +689,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_macros"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
|
@ -698,7 +698,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_sqlite3_parser"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"cc",
|
||||
|
@ -717,7 +717,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_time"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"chrono",
|
||||
"limbo_ext",
|
||||
|
@ -729,7 +729,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "limbo_uuid"
|
||||
version = "0.0.17"
|
||||
version = "0.0.18-pre.3"
|
||||
dependencies = [
|
||||
"limbo_ext",
|
||||
"mimalloc",
|
||||
|
|
43
fuzz/README.md
Normal file
43
fuzz/README.md
Normal file
|
@ -0,0 +1,43 @@
|
|||
# Limbo Fuzzing
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Ensure you have the following installed:
|
||||
|
||||
- Nightly Rust toolchain (required for `cargo-fuzz` unless using Nix)
|
||||
- `cargo-fuzz` (install it using `cargo install cargo-fuzz`)
|
||||
- Nix (if using a `flake.nix` setup)
|
||||
|
||||
## Using Nix
|
||||
|
||||
```sh
|
||||
nix develop .#fuzz
|
||||
```
|
||||
|
||||
This will set up the required environment with the nightly toolchain and
|
||||
dependencies.
|
||||
|
||||
## Running the Fuzzer
|
||||
|
||||
If using Nix:
|
||||
|
||||
```sh
|
||||
cargo fuzz run <fuzz_target>
|
||||
```
|
||||
|
||||
If using `rustup` without Nix:
|
||||
|
||||
```sh
|
||||
cargo +nightly fuzz run <fuzz_target>
|
||||
```
|
||||
|
||||
This will compile the fuzz target and start fuzzing with `libFuzzer`.
|
||||
|
||||
## Example
|
||||
|
||||
Run the expression target with:
|
||||
|
||||
```sh
|
||||
cargo fuzz run expression
|
||||
```
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue