[package] name = "leveva-cidr" version = "0.0.0" edition = "2021" publish = false description = "Pure CIDR network-mask helpers: parse `addr/prefix`, test network membership, and compute the masked network base — IPv4 and IPv6, no v4-mapped normalization." # Extracted from `leveva` (the IRC daemon) as a self-contained leaf library: every # function is pure and depends only on `std::net`, with zero IRC-specific coupling, # while `matching` (host masks), `connlimit` (per-CIDR accounting), and the # `websocket` proxy-trust list all depend on *it*. It is the safe successor of the C # `ircd`'s `match_ipmask`. `leveva` re-exports it as `leveva::cidr`. [lib] path = "src/lib.rs" [dependencies] [dev-dependencies] # Property/fuzz tests: the parse/contains/network_base/cidr_match invariants are fed # arbitrary IP addresses and prefix lengths. Stable-toolchain fuzz tier — the project # has no nightly/cargo-fuzz, so proptest is the runnable fuzzer. proptest = "1"