Skip to main content

CaptureHook

Type Alias CaptureHook 

Source
pub type CaptureHook = Arc<dyn Fn(CapturePath, &[u8]) + Sync + Send>;
Expand description

A debug packet-capture hook. When installed on a DataPlane, it is invoked with the path and the raw IP packet bytes for every plaintext packet crossing the datapath. It must be cheap and non-blocking — it runs inline on the single-threaded dataplane step, so a slow hook backs up the datapath. Wrapped in Arc so it is cheap to clone and Send + Sync for the actor that installs it.

Aliased Type§

pub struct CaptureHook { /* private fields */ }