78 lines
2.4 KiB
Text
78 lines
2.4 KiB
Text
# apparmor.d - Full set of apparmor profiles
|
|
# Copyright (C) 2023-2024 Alexandre Pujol <alexandre@pujol.io>
|
|
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
abi <abi/4.0>,
|
|
|
|
include <tunables/global>
|
|
|
|
@{exec_path} = @{bin}/baloo_file @{lib}/{,kf6/}baloo_file
|
|
@{exec_path} += @{lib}/@{multiarch}/{,libexec/}baloo_file
|
|
profile baloo @{exec_path} {
|
|
include <abstractions/base>
|
|
include <abstractions/deny-sensitive-home>
|
|
include <abstractions/disks-read>
|
|
include <abstractions/fontconfig-cache-write>
|
|
include <abstractions/graphics>
|
|
include <abstractions/kde-strict>
|
|
include <abstractions/nameservice-strict>
|
|
include <abstractions/private-files-strict>
|
|
|
|
network netlink raw,
|
|
|
|
@{exec_path} mr,
|
|
|
|
@{lib}/{,kf6/}baloo_file_extractor rix,
|
|
|
|
/usr/share/poppler/{,**} r,
|
|
|
|
/etc/fstab r,
|
|
/etc/machine-id r,
|
|
|
|
# Allow to search user files
|
|
owner @{HOME}/{,**} r,
|
|
owner @{MOUNTS}/{,**} r,
|
|
owner @{tmp}/*/{,**} r,
|
|
|
|
owner @{user_cache_dirs}/kcrash-metadata/ w,
|
|
|
|
owner @{user_config_dirs}/#@{int} rw,
|
|
owner @{user_config_dirs}/baloofilerc rwl,
|
|
owner @{user_config_dirs}/baloofilerc.lock rwkl,
|
|
|
|
owner @{user_share_dirs}/baloo/{,**} rwk,
|
|
|
|
@{run}/mount/utab r,
|
|
|
|
@{run}/udev/data/+*:* r,
|
|
|
|
@{run}/udev/data/c1:@{int} r, # For RAM disk
|
|
@{run}/udev/data/c4:@{int} r, # For TTY devices
|
|
@{run}/udev/data/c5:@{int} r, # for /dev/tty, /dev/console, /dev/ptmx
|
|
@{run}/udev/data/c7:@{int} r, # For Virtual console capture devices
|
|
@{run}/udev/data/c10:@{int} r, # For non-serial mice, misc features
|
|
@{run}/udev/data/c13:@{int} r, # For /dev/input/*
|
|
@{run}/udev/data/c29:@{int} r, # For /dev/fb[0-9]*
|
|
@{run}/udev/data/c81:@{int} r, # For video4linux
|
|
@{run}/udev/data/c89:@{int} r, # For I2C bus interface
|
|
@{run}/udev/data/c99:@{int} r, # For raw parallel ports /dev/parport*
|
|
@{run}/udev/data/c116:@{int} r, # For ALSA
|
|
@{run}/udev/data/c202:@{int} r, # CPU model-specific registers
|
|
@{run}/udev/data/c203:@{int} r, # CPU CPUID information
|
|
@{run}/udev/data/c226:@{int} r, # For /dev/dri/card[0-9]*
|
|
@{run}/udev/data/c@{dynamic}:@{int} r, # For dynamic assignment range 234 to 254, 384 to 511
|
|
|
|
@{sys}/bus/ r,
|
|
@{sys}/bus/*/devices/ r,
|
|
@{sys}/class/*/ r,
|
|
@{sys}/devices/**/uevent r,
|
|
|
|
owner @{PROC}/@{pid}/mounts r,
|
|
owner @{PROC}/@{pid}/mountinfo r,
|
|
|
|
/dev/tty r,
|
|
|
|
include if exists <local/baloo>
|
|
}
|
|
|
|
# vim:syntax=apparmor
|