Files
systemd/units/systemd-varlink-monitord@.service.in
Sebastian Wick 05d309f852 varlink-monitord: Add BPF-based varlink traffic monitor daemon
Add systemd-varlink-monitord, a daemon that uses BPF LSM and fentry
hooks to capture varlink protocol traffic on AF_UNIX sockets. Sockets
are classified as varlink by reading the user.varlink xattr. The daemon
exposes a varlink API with Setup/Start/Stop methods and passes a ring
buffer fd to the client for zero-copy packet delivery. Unprivileged
callers can only see their own traffic; polkit authorization grants full
access.
2026-10-14 13:53:03 +02:00

39 lines
1.0 KiB
Plaintext

# SPDX-License-Identifier: LGPL-2.1-or-later
#
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
[Unit]
Description=Varlink Monitor
Documentation=man:systemd-varlink-monitord.service(8)
[Service]
DynamicUser=yes
AmbientCapabilities=CAP_BPF CAP_PERFMON
CapabilityBoundingSet=CAP_BPF CAP_PERFMON
ExecStart={{LIBEXECDIR}}/systemd-varlink-monitord
IPAddressDeny=any
LockPersonality=yes
MemoryDenyWriteExecute=yes
NoNewPrivileges=yes
PrivateDevices=yes
PrivateTmp=disconnected
ProtectClock=yes
ProtectHome=yes
ProtectHostname=yes
ProtectKernelLogs=yes
ProtectKernelModules=yes
ProtectKernelTunables=yes
ProtectSystem=strict
RestrictAddressFamilies=AF_UNIX
RestrictNamespaces=yes
RestrictRealtime=yes
RestrictSUIDSGID=yes
SystemCallArchitectures=native
SystemCallErrorNumber=EPERM
SystemCallFilter=@system-service bpf perf_event_open