A modern fanotify wrapper.
Safe bindings are completed and can be used.
Note: This is still under development.
```rust use libc::AT_FDCWD; use naughtyfy::api::; use naughtyfy::flags::;
fn main() { unsafe { FANEVENTBUFFERLEN = 230; } let fd = fanotifyinit(FANCLASSNOTIF, 0).unwrap(); fanotifymark(fd, FANMARKADD | FANMARKMOUNT, FANACCESS, ATFDCWD, "/").unwrap(); let mut iter = 10; loop { let res = fanotifyread(fd).unwrap(); println!("{res:#?}"); iter += 1; if iter > 10 { break; } } fanotify_close(fd).unwrap(); } ```
Build example using
cargo build --release --example lowkey
Run lowkey
using
sudo ./target/release/examples/lowkey