24 stable releases

new 1.2.24 Mar 18, 2025
1.2.22 Dec 30, 2024
1.2.21 Sep 25, 2024
1.2.19 May 22, 2024
0.1.0 Jul 3, 2020

#140 in Network programming

Download history 1157/week @ 2024-11-30 1153/week @ 2024-12-07 1370/week @ 2024-12-14 916/week @ 2024-12-21 1110/week @ 2024-12-28 1319/week @ 2025-01-04 1250/week @ 2025-01-11 1448/week @ 2025-01-18 1176/week @ 2025-01-25 1442/week @ 2025-02-01 1832/week @ 2025-02-08 1851/week @ 2025-02-15 1680/week @ 2025-02-22 1985/week @ 2025-03-01 2084/week @ 2025-03-08 2307/week @ 2025-03-15

8,290 downloads per month
Used in 8 crates (7 directly)

Apache-2.0

320KB
9K SLoC

The nispor(Network Inspector) project is designed to providing unified interface for Linux network state querying.

Currently providing:

  • Rust crate
  • Python binding
  • C binding
  • Command line tool -- npc

Install

make
sudo PREFIX=/usr make install

Usage

Print all network status

npc

Print network status of certain NIC

npc bond99

Print route entries

npc route

Supported features

  • IPv4/IPv6 address
  • Bond
  • Linux Bridge
  • Linux Bridge VLAN filtering
  • VLAN
  • VxLAN
  • Route
  • Dummy
  • TUN/TAP
  • Veth
  • VRF(Virtual Routing and Forwarding)
  • SR-IOV
  • MacVlan
  • MacVtap

TODO:

  • Error handling instead of unwrap()/panic!/etc
  • SR-IOV VF-PF relation is possible
  • VLAN QoS
  • Route rule
  • Traffic control
  • Manpage for npc/npd
  • pkgconfig file for nispor C library

What should nispor not do

To make nispor only to small good things, this is the list of things could be done by nispor but should not do:

  • Ordering the network interface configuration base on child/parent, controller/port relationships.
  • Wrapping of multiple kernel options into simple ones.
  • User space networking.
  • Notification on network change.

Dependencies

~7–14MB
~185K SLoC