| Crates.io | ipfilter |
| lib.rs | ipfilter |
| version | 0.0.1 |
| created_at | 2025-03-12 03:16:54.454796+00 |
| updated_at | 2025-03-12 03:50:07.722035+00 |
| description | A library to streamline IP filtering |
| homepage | |
| repository | https://github.com/QuantumShade/ipfilter |
| max_upload_size | |
| id | 1589326 |
| size | 6,935 |
use core::net::Ipv4Addr;
use std::fs::File;
fn main() {
let file = File::open("whitelist.bin").unwrap();
let whitelist = ipfilter::v4::read_from(&mut &file).unwrap();
assert!(whitelist.contains(&Ipv4Addr::LOCALHOST));
}