Ekko aims to be a light utility for sending echo requests; currently in its early stages.
To use ekko
, add this to your Cargo.toml
:
toml
[dependencies]
ekko = "0.5.0"
The following example will trace the route to the specified destination. ```rust use ekko::{
error::{EkkoError},
EkkoResponse,
Ekko,
};
fn main() -> Result<(), EkkoError> { let mut sender = Ekko::with_target(([8, 8, 8, 8], 0))?;
for hops in 0..64 {
let responses = sender.send_range(0..(hops))?;
for ekko in responses.iter() {
match ekko {
EkkoResponse::Destination(_) => {
for ekko in responses.iter() {
println!("{:?}", ekko)
}
return Ok(())
}
_ => continue
}
}
}
Ok(())
} ```
All contributions are welcome, don't hesitate to open an issue if something is missing!