diff options
| author | zedddie <rust@zedddie.rs> | 2026-03-15 15:44:34 +0100 |
|---|---|---|
| committer | tuturuu <zedddiezxc@gmail.com> | 2026-03-15 15:44:34 +0100 |
| commit | e8b24118643e91ecda03d353cfbfea535a2b18dc (patch) | |
| tree | 3f48849c0d8e18577a30c6b64a255c1b8fb5916f /src/startup.rs | |
| parent | 06d4e558cdf97b64e4cbc95becf1b25c1c24950e (diff) | |
sniff things wip
Diffstat (limited to 'src/startup.rs')
| -rw-r--r-- | src/startup.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/startup.rs b/src/startup.rs index 32ed278..b9e0191 100644 --- a/src/startup.rs +++ b/src/startup.rs @@ -1,5 +1,6 @@ // Here we iniitialize systems crucial for nsc use std::io::Read; +use sniffing::headers::sniff_raw_packets; pub fn init() -> Result<(), Box<dyn std::error::Error + Send + Sync + 'static>> { let mut config = tun::Configuration::default(); @@ -20,6 +21,8 @@ pub fn init() -> Result<(), Box<dyn std::error::Error + Send + Sync + 'static>> loop { let amount = dev.read(&mut buf)?; - println!("{:?}", &buf[0..amount]); + sniff_raw_packets(&buf[0..amount]); + dbg!("{:?}", &buf[0..amount]); + } } |
