apparmor.d/apparmor.d/groups/ubuntu/software-properties-gtk
2025-08-28 21:09:09 +02:00

90 lines
2.8 KiB
Text

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2022-2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/4.0>,
include <tunables/global>
@{exec_path} = @{bin}/software-properties-gtk
profile software-properties-gtk @{exec_path} flags=(attach_disconnected) {
include <abstractions/base>
include <abstractions/audio-client>
include <abstractions/bus-accessibility>
include <abstractions/bus-session>
include <abstractions/bus-system>
include <abstractions/bus/org.a11y>
include <abstractions/bus/org.freedesktop.portal.Desktop>
include <abstractions/bus/org.gtk.vfs.MountTracker>
include <abstractions/common/apt>
include <abstractions/dconf-write>
include <abstractions/gnome-strict>
include <abstractions/nameservice-strict>
include <abstractions/python>
#aa:dbus own bus=session name=com.ubuntu.SoftwareProperties
#aa:dbus talk bus=system name=com.canonical.UbuntuAdvantage label=ubuntu-advantage-desktop-daemon
#aa:dbus talk bus=system name=com.ubuntu.SoftwareProperties path=/ label=software-properties-dbus
@{exec_path} mr,
@{bin}/ r,
@{sh_path} rix,
@{python_path} r,
@{bin}/aplay rPx,
@{bin}/apt-key rPx,
@{bin}/dpkg rPx -> child-dpkg,
@{bin}/ischroot rPx,
@{bin}/lsb_release rPx,
@{bin}/ubuntu-advantage rPx,
/usr/share/distro-info/*.csv r,
/usr/share/pixmaps/ r,
/usr/share/python-apt/{,**} r,
/usr/share/software-properties/{,**} r,
/usr/share/themes/{,**} r,
/usr/share/ubuntu-drivers-common/detect/{,**} r,
/usr/share/X11/xkb/{,**} r,
/usr/share/xml/iso-codes/{,**} r,
/usr/share/software-properties/gtkbuilder/* r,
/usr/share/xkeyboard-config-2/{,**} r,
/etc/apport/blacklist.d/{,*} r,
/etc/default/apport r,
/etc/update-manager/release-upgrades r,
/var/crash/*software-properties-gtk.@{uid}.crash rw,
/var/lib/ubuntu-advantage/status.json r,
owner @{tmp}/@{word8} rw,
owner @{tmp}/tmp@{word8}/ rw,
owner @{tmp}/tmp@{word8}/apt.conf rw,
/dev/shm/ r,
owner /dev/shm/sem.@{rand6} rwl -> /dev/shm/sem.@{rand6},
owner /dev/shm/sem.mp-@{rand8} rwl -> /dev/shm/sem.@{rand6},
owner @{run}/user/@{uid}/gnome-shell-disable-extensions w,
@{sys}/devices/ r,
@{sys}/devices/**/ r,
@{sys}/devices/**/modalias r,
@{PROC}/@{pids}/mountinfo r,
@{PROC}/asound/cards r,
owner @{PROC}/@{pid}/cgroup r,
owner @{PROC}/@{pid}/cmdline r,
owner @{PROC}/@{pid}/environ r,
owner @{PROC}/@{pid}/fd/ r,
owner @{PROC}/@{pid}/mounts r,
owner @{PROC}/@{pid}/stat r,
# Silencer
deny @{user_share_dirs}/gvfs-metadata/* r,
include if exists <local/software-properties-gtk>
}
# vim:syntax=apparmor