Skip to content

Get your local IP address in Rust.

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT
Notifications You must be signed in to change notification settings

AndyGauge/rust-local-ip

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

local-ip

Get your local ip address in Rust.

local-ip = "0.2"

then

extern crate local_ip;

let ip = local_ip::get().unwrap();
println!("local ip address: {:?}", ip.to_string());

Design

local-ip should not rely on any syscall or FFI interfaces (there are other crates for this purpose). As a result, installation should be trivial. Instead, it parses the output of ipconfig or ifconfig depending on the OS.

License

MIT or Apache-2.0, at your option.

About

Get your local IP address in Rust.

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 100.0%