Add a per-process network information plugin

Authored by ahiemstra on Sep 2 2019, 9:48 AM.

Description

Add a per-process network information plugin

Summary:
This adds a ksysguard process plugin that provides information about
how much data is being used by a certain process. Since there is no
unpriviledged API available (yet?) for this information, a small
helper application is used that uses libpcap to capture packet sizes,
which is then mapped to individual processes by comparing sockets to
entries in /proc.

The helper application is intentionally kept small and should not
require anything else than cap_net_raw.

Depends on D23287

Test Plan:
Ensure ksgrd_network_helper has cap_net_raw set, by running
setcap cap_net_raw+ep ksgrd_network_helper. After that, start
ksysguard. The "upload" and "download" columns should be
automatically enabled and display network traffic for a certain
process.

Reviewers: Plasma, meven

Reviewed By: meven

Subscribers: meven, davidedmundson, plasma-devel

Tags: Plasma

Differential Revision: https://phabricator.kde.org/D23342

Details

Committed
ahiemstraSep 16 2019, 9:24 AM
Reviewer
meven
Differential Revision
D23342: Add a per-process network information plugin
Parents
R106:774764b0c5e8: HiDPI icon in buttons and menus
Branches
Unknown
Tags
Unknown