rscamper-0.1.0 has been yanked.
rscamper
A safe Rust interface to CAIDA's scamper network measurement tool.
rscamper wraps the scamper C libraries (libscamperfile and libscamperctrl) through Rust
FFI, providing idiomatic Rust types for all measurement data structures and a safe async-friendly
control loop.
Features
- File I/O — read and write scamper warts/JSON files via
ScamperFile - Control loop — connect to a running scamper daemon and issue measurements via
ScamperCtrl - All measurement types —
trace,ping,tracelb,dealias,host,http,tbit,sniff,udpprobe,owamp,sting,neighbourdisc - Mux / VP support — enumerate and connect to vantage points via
ScamperMuxandScamperVp
Prerequisites
rscamper links against libscamperfile and libscamperctrl, which are part of the scamper
distribution. Build and install scamper from source following the
official instructions.
By default, the libraries are searched for in /usr/local/lib and /usr/lib. If you installed
scamper to a custom prefix, set the SCAMPER_LIB_DIR environment variable at build time:
SCAMPER_LIB_DIR=/opt/scamper/lib
Installation
Add rscamper to your Cargo.toml:
[]
= "0.1"
Usage
Reading a warts file
use ;
let file = open.unwrap;
for obj in file
Running a measurement via scamper daemon
use Duration;
use ;
let mut ctrl = new.unwrap;
// Connect to a scamper daemon listening on TCP port 31337.
let inst = ctrl.add_inet.unwrap;
ctrl.do_ping.unwrap;
inst.done;
for item in ctrl.responses
Mux / vantage points
use ScamperCtrl;
let mut ctrl = new.unwrap;
let _mux_inst = ctrl.add_inet.unwrap;
for vp in ctrl.vps
License
GPL-3.0-only — see the GNU General Public License for details.