Rhai made a decision about a route cost one to three microseconds, some two hundred times what the same costs in Rust. That was bearable where a function is asked once for an UPDATE, and is not where every route is weighed against every peer, as it is when routes are passed on. What is wanted of a policy (mark routes by where they came from, mark what is announced, let communities say who is told what) needs no language; it is to be configuration, done natively. Kept from that work: route selection goes by a LOCAL_PREF that policy set on a route from an external peer, and the lab's configuration can be added to by a phase. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
79 lines
1.4 KiB
TOML
79 lines
1.4 KiB
TOML
# Coverage-guided fuzz targets, run with cargo-fuzz on a nightly toolchain.
|
|
# See README.md in this directory.
|
|
[package]
|
|
name = "bgp-fuzz"
|
|
version = "0.0.0"
|
|
edition = "2024"
|
|
license = "Apache-2.0"
|
|
publish = false
|
|
|
|
[package.metadata]
|
|
cargo-fuzz = true
|
|
|
|
# Not part of the main workspace: libfuzzer needs nightly, the workspace
|
|
# builds on stable.
|
|
[workspace]
|
|
|
|
[dependencies]
|
|
bgp-packet = { path = "../crates/packet" }
|
|
bgp-primitives = { path = "../crates/primitives" }
|
|
bgp-fib = { path = "../crates/fib" }
|
|
bgp-rib = { path = "../crates/rib" }
|
|
bgp-rpki = { path = "../crates/rpki" }
|
|
bgp-server = { path = "../crates/server" }
|
|
bytes = "1.10.1"
|
|
libfuzzer-sys = "0.4"
|
|
protobuf = "3.7.2"
|
|
|
|
[lib]
|
|
path = "src/lib.rs"
|
|
|
|
[[bin]]
|
|
name = "attrs"
|
|
path = "fuzz_targets/attrs.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "message"
|
|
path = "fuzz_targets/message.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "message_body"
|
|
path = "fuzz_targets/message_body.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "prefix_text"
|
|
path = "fuzz_targets/prefix_text.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "config"
|
|
path = "fuzz_targets/config.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "rtr"
|
|
path = "fuzz_targets/rtr.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|
|
|
|
[[bin]]
|
|
name = "netlink"
|
|
path = "fuzz_targets/netlink.rs"
|
|
test = false
|
|
doc = false
|
|
bench = false
|