13 stable releases

1.2.18 Mar 19, 2024
1.2.16 Dec 22, 2023
1.2.14 Sep 18, 2023
1.2.10 Jan 31, 2023
1.2.5 Mar 30, 2022

#1733 in Network programming

Download history 2/week @ 2023-12-18 6/week @ 2024-01-29 85/week @ 2024-02-12 4/week @ 2024-02-19 15/week @ 2024-02-26 137/week @ 2024-03-18 214/week @ 2024-04-01

351 downloads per month

Apache-2.0

330KB
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

~16MB
~289K SLoC