eltrafico

Crates.ioeltrafico
lib.rseltrafico
version2.3.0
sourcesrc
created_at2020-01-07 10:44:25.056134
updated_at2021-10-20 17:45:46.215072
descriptionNetLimiter-like traffic shaping for Linux
homepage
repositoryhttps://github.com/sigmaSd/Eltrafico/
max_upload_size
id196092
size187,231
Bedis Nbiba (sigmaSd)

documentation

README

Eltrafico

NetLimiter-like traffic shaping for Linux

This is a port of https://github.com/cryzed/TrafficToll to rust.

And a gui on top

With network usage:

Usage

eltrafico

Howto

Choose the correct interface, and eltrafico will monitor it for active connections

Active program will automatically show up

Choose your limits then activate it by toggling the corresponding checkbox on.

If bandwhich or nethogs is installed on your system, eltrafico will use it automatically to show programs live network usage

Technical details

Eltrafico is split on 2 binaries that communicate through stdin/out:

1- eltrafico: create gui and call bandwhich/nethogs and eltrafico_tc as privileged process using pkexec

2- eltrafico_tc: traffic shaping, can be controlled via stdin, for the list of commands see https://github.com/sigmaSd/Eltrafico/blob/sudo_isolation/src/eltrafico_tc/main.rs#L252 and https://github.com/sigmaSd/Eltrafico/blob/sudo_isolation/src/eltrafico_tc/main.rs#L79

This allows to run the gui as a normal user, and ask for higher privilege only for eltrafico_tc and bandwhich/nethogs binaries

eltrafico_tc needs to be in $PATH or you can specify a custom path via --eltrafico-tc $path_to_binary

pkexec usage:

  • pkexec eltrafico_tc
  • pkexec bandhwich
  • pkexec nethogs
  • pkexec pkill nethogs
  • pkexec pkill bandwhich

Current State

Works on my pc (TM)

Dependencies

  • iproute2

optional:

Binary Releases

Installation

Building/Dev

Changelog

Commit count: 154

cargo fmt