feat(profile): general update.

This commit is contained in:
Alexandre Pujol 2024-02-07 13:50:40 +00:00
parent 9b705ab76c
commit cdaf72eb3d
Failed to generate hash of commit
22 changed files with 31 additions and 63 deletions

View file

@ -17,6 +17,7 @@ profile ibus-memconf @{exec_path} {
@{exec_path} mr, @{exec_path} mr,
/etc/machine-id r, /etc/machine-id r,
/var/lib/dbus/machine-id r,
/var/lib/gdm{3,}/.config/ibus/bus/ r, /var/lib/gdm{3,}/.config/ibus/bus/ r,
/var/lib/gdm{3,}/.config/ibus/bus/@{md5}-unix-{,wayland-}@{int} r, /var/lib/gdm{3,}/.config/ibus/bus/@{md5}-unix-{,wayland-}@{int} r,

View file

@ -33,7 +33,7 @@ profile pipewire-media-session @{exec_path} {
/usr/share/alsa-card-profile/{,**} r, /usr/share/alsa-card-profile/{,**} r,
/usr/share/pipewire/*.conf r, /usr/share/pipewire/*.conf r,
/usr/share/pipewire/media-session.d/{,**} r, /usr/share/pipewire/media-session.d/{,**} r,
/usr/share/spa-*/bluez[0-9]*/{,*} r, /usr/share/spa-*/bluez@{int}/{,*} r,
/etc/pipewire/*.conf r, /etc/pipewire/*.conf r,
/etc/pipewire/media-session.d/*.conf r, /etc/pipewire/media-session.d/*.conf r,
@ -48,7 +48,7 @@ profile pipewire-media-session @{exec_path} {
owner @{user_config_dirs}/pipewire/** rw, owner @{user_config_dirs}/pipewire/** rw,
owner @{user_config_dirs}/pulse/ rw, owner @{user_config_dirs}/pulse/ rw,
owner @{run}/user/@{uid}/pipewire-[0-9]* rw, owner @{run}/user/@{uid}/pipewire-@{int} rw,
@{run}/udev/data/c116:@{int} r, # for ALSA @{run}/udev/data/c116:@{int} r, # for ALSA

View file

@ -20,8 +20,7 @@ profile pulseaudio @{exec_path} {
include <abstractions/bus/org.freedesktop.RealtimeKit1> include <abstractions/bus/org.freedesktop.RealtimeKit1>
include <abstractions/consoles> include <abstractions/consoles>
include <abstractions/dconf-write> include <abstractions/dconf-write>
include <abstractions/dri-common> include <abstractions/dri>
include <abstractions/dri-enumerate>
include <abstractions/fontconfig-cache-write> include <abstractions/fontconfig-cache-write>
include <abstractions/fonts> include <abstractions/fonts>
include <abstractions/freedesktop.org> include <abstractions/freedesktop.org>

View file

@ -82,7 +82,7 @@ profile xdg-desktop-portal @{exec_path} flags=(attach_disconnected) {
owner /tmp/icon* rw, owner /tmp/icon* rw,
owner @{run}/user/@{uid}/.flatpak/{,*/*} r, owner @{run}/user/@{uid}/.flatpak/{,*/*} r,
owner @{run}/user/@{uid}/pipewire-[0-9]* rw, owner @{run}/user/@{uid}/pipewire-@{int} rw,
@{PROC}/ r, @{PROC}/ r,
@{PROC}/*/ r, @{PROC}/*/ r,

View file

@ -33,7 +33,7 @@ profile epiphany-search-provider @{exec_path} {
owner @{user_share_dirs}/epiphany/{,**} rwk, owner @{user_share_dirs}/epiphany/{,**} rwk,
owner /tmp/ContentRuleList@{rand6} rw, owner /tmp/ContentRuleList@{rand6} rw,
owner /tmp/Serialized* rw, owner /tmp/Serialized* rw,
@{sys}/devices/virtual/dmi/id/chassis_type r, @{sys}/devices/virtual/dmi/id/chassis_type r,
@{sys}/fs/cgroup/user.slice/user-@{uid}.slice/user@@{uid}.service/app.slice/*org.gnome.Epiphany.SearchProvider.slice/*/memory.* r, @{sys}/fs/cgroup/user.slice/user-@{uid}.slice/user@@{uid}.service/app.slice/*org.gnome.Epiphany.SearchProvider.slice/*/memory.* r,

View file

@ -87,7 +87,7 @@ profile gdm-session-worker @{exec_path} flags=(attach_disconnected) {
owner @{HOME}/.pam_environment r, owner @{HOME}/.pam_environment r,
owner @{run}/systemd/seats/seat@{int} r, owner @{run}/systemd/seats/seat@{int} r,
owner @{run}/user/@{uid}/keyring/control rw, owner @{run}/user/@{uid}/keyring/control rw,
@{run}/cockpit/active.motd r, @{run}/cockpit/active.motd r,
@{run}/faillock/[a-zA-z0-9]* rwk, @{run}/faillock/[a-zA-z0-9]* rwk,

View file

@ -72,7 +72,6 @@ profile gnome-control-center @{exec_path} flags=(attach_disconnected) {
/usr/share/thumbnailers/{,*} r, /usr/share/thumbnailers/{,*} r,
/usr/share/wallpapers/{,**} r, /usr/share/wallpapers/{,**} r,
/usr/share/xml/iso-codes/iso_[0-9]*-[0-9]*.xml r, /usr/share/xml/iso-codes/iso_[0-9]*-[0-9]*.xml r,
/usr/share/zoneinfo/{,**} r,
/etc/cups/client.conf r, /etc/cups/client.conf r,
/etc/machine-info r, /etc/machine-info r,
@ -111,7 +110,7 @@ profile gnome-control-center @{exec_path} flags=(attach_disconnected) {
owner @{run}/user/@{uid}/gnome-shell-disable-extensions w, owner @{run}/user/@{uid}/gnome-shell-disable-extensions w,
owner @{run}/user/@{uid}/gnome-control-center-region-needs-restart w, owner @{run}/user/@{uid}/gnome-control-center-region-needs-restart w,
owner @{run}/user/@{uid}/pipewire-[0-9]* rw, owner @{run}/user/@{uid}/pipewire-@{int} rw,
owner @{run}/user/@{uid}/gvfsd/socket-@{rand8} rw, owner @{run}/user/@{uid}/gvfsd/socket-@{rand8} rw,
@{run}/cups/cups.sock rw, @{run}/cups/cups.sock rw,
@{run}/samba/ rw, @{run}/samba/ rw,

View file

@ -115,8 +115,9 @@ profile gnome-session-binary @{exec_path} flags=(attach_disconnected) {
@{etc_ro}/xdg/autostart/{,*.desktop} r, @{etc_ro}/xdg/autostart/{,*.desktop} r,
/var/lib/gdm{3,}/.cache/gdm/Xauthority r,
/var/lib/gdm{3,}/.cache/mesa_shader_cache/index rw, /var/lib/gdm{3,}/.cache/mesa_shader_cache/index rw,
/var/lib/gdm{3,}/.config/dconf/user r, /var/lib/gdm{3,}/.config/dconf/user rw,
/var/lib/gdm{3,}/.config/gnome-session/ rw, /var/lib/gdm{3,}/.config/gnome-session/ rw,
/var/lib/gdm{3,}/.config/gnome-session/saved-session/ rw, /var/lib/gdm{3,}/.config/gnome-session/saved-session/ rw,
/var/lib/gdm{3,}/.local/share/applications/{,**} r, /var/lib/gdm{3,}/.local/share/applications/{,**} r,

View file

@ -249,7 +249,7 @@ profile gnome-shell @{exec_path} flags=(attach_disconnected) {
/var/lib/gdm{3,}/.cache/ w, /var/lib/gdm{3,}/.cache/ w,
/var/lib/gdm{3,}/.cache/event-sound-cache.tdb.@{md5}.x86_64-pc-linux-gnu rwk, /var/lib/gdm{3,}/.cache/event-sound-cache.tdb.@{md5}.x86_64-pc-linux-gnu rwk,
/var/lib/gdm{3,}/.cache/fontconfig/{,*} rwl, /var/lib/gdm{3,}/.cache/fontconfig/{,*} rwl,
/var/lib/gdm{3,}/.cache/gstreamer-@{int}/ rw, /var/lib/gdm{3,}/.cache/gstreamer-@{int}/ rw,
/var/lib/gdm{3,}/.cache/gstreamer-@{int}/registry.*.bin{,.tmp@{rand6}} rw, /var/lib/gdm{3,}/.cache/gstreamer-@{int}/registry.*.bin{,.tmp@{rand6}} rw,
/var/lib/gdm{3,}/.cache/libgweather/ r, /var/lib/gdm{3,}/.cache/libgweather/ r,

View file

@ -15,7 +15,7 @@ profile grub-mount @{exec_path} {
capability sys_admin, capability sys_admin,
mount fstype=fuse.grub-mount -> /var/lib/os-prober/mount/, mount fstype=fuse.grub-mount -> /var/lib/os-prober/mount/,
umount /var/lib/os-prober/mount/, umount /var/lib/os-prober/mount/,
@{exec_path} mr, @{exec_path} mr,

View file

@ -16,7 +16,7 @@ profile netplan.script @{exec_path} flags=(attach_disconnected) {
@{lib}/netplan/generate rix, @{lib}/netplan/generate rix,
@{bin}/udevadm rCx -> udevadm, @{bin}/udevadm rCx -> udevadm,
@{bin}/systemctl rCx -> systemctl, @{bin}/systemctl rCx -> systemctl,
/usr/share/netplan/{,**} r, /usr/share/netplan/{,**} r,

View file

@ -105,7 +105,6 @@ profile sshd @{exec_path} flags=(attach_disconnected) {
@{PROC}/@{pids}/fd/ r, @{PROC}/@{pids}/fd/ r,
@{PROC}/1/environ r, @{PROC}/1/environ r,
@{PROC}/cmdline r, @{PROC}/cmdline r,
@{PROC}/sys/kernel/ngroups_max r,
owner @{PROC}/@{pid}/limits r, owner @{PROC}/@{pid}/limits r,
owner @{PROC}/@{pid}/loginuid rw, owner @{PROC}/@{pid}/loginuid rw,
owner @{PROC}/@{pid}/mounts r, owner @{PROC}/@{pid}/mounts r,

View file

@ -1,16 +0,0 @@
# 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/3.0>,
include <tunables/global>
@{exec_path} = @{lib}/systemd/user-environment-generators/60-flatpak
profile systemd-generator-user-environment-flatpak @{exec_path} {
include <abstractions/base>
@{exec_path} mr,
include if exists <local/systemd-generator-user-environment-flatpak>
}

View file

@ -92,7 +92,7 @@ profile torbrowser @{exec_path} flags=(attach_disconnected) {
owner /tmp/@{name}/* rwk, owner /tmp/@{name}/* rwk,
owner /tmp/Temp-@{uuid}/ rw, owner /tmp/Temp-@{uuid}/ rw,
owner "/tmp/Tor Project*/" rw, owner "/tmp/Tor Project*/" rw,
owner "/tmp/Tor Project*/**" rwk, owner "/tmp/Tor Project*/**" rwk,
owner "/tmp/Tor Project*" rwk, owner "/tmp/Tor Project*" rwk,
@{run}/mount/utab r, @{run}/mount/utab r,

View file

@ -18,7 +18,7 @@ profile gsettings @{exec_path} {
/usr/share/dconf/profile/gdm r, /usr/share/dconf/profile/gdm r,
/usr/share/gdm/greeter-dconf-defaults r, /usr/share/gdm/greeter-dconf-defaults r,
/var/lib/gdm{3,}/.config/dconf/user r, /var/lib/gdm{3,}/.config/dconf/user rw,
/var/lib/gdm{3,}/greeter-dconf-defaults r, /var/lib/gdm{3,}/greeter-dconf-defaults r,
/dev/tty@{int} rw, /dev/tty@{int} rw,

View file

@ -35,8 +35,8 @@ profile ip @{exec_path} flags=(attach_disconnected) {
/etc/iproute2/{,**} r, /etc/iproute2/{,**} r,
/etc/netns/*/ r, /etc/netns/*/ r,
owner @{run}/netns/ rw,
@{run}/netns/* rw, @{run}/netns/* rw,
owner @{run}/netns/ rw,
owner @{PROC}/@{pid}/cgroup r, owner @{PROC}/@{pid}/cgroup r,
owner @{PROC}/@{pid}/net/dev_mcast r, owner @{PROC}/@{pid}/net/dev_mcast r,

View file

@ -60,7 +60,6 @@ profile mount-nfs @{exec_path} flags=(complain) {
owner @{run}/mount/utab{,.*} rw, owner @{run}/mount/utab{,.*} rw,
owner @{run}/rpc.statd.lock wk, owner @{run}/rpc.statd.lock wk,
@{PROC}/filesystems r,
owner @{PROC}/@{pid}/mountinfo r, owner @{PROC}/@{pid}/mountinfo r,
include if exists <local/mount-nfs> include if exists <local/mount-nfs>

View file

@ -7,9 +7,6 @@ abi <abi/3.0>,
include <tunables/global> include <tunables/global>
@{FIREFOX_BIN} = @{lib}/firefox{,-esr}/firefox
@{FIREFOX_BIN} += /opt/firefox{,-esr}/firefox
@{exec_path} = @{bin}/qbittorrent @{exec_path} = @{bin}/qbittorrent
profile qbittorrent @{exec_path} { profile qbittorrent @{exec_path} {
include <abstractions/base> include <abstractions/base>
@ -20,25 +17,17 @@ profile qbittorrent @{exec_path} {
include <abstractions/bus/org.kde.StatusNotifierWatcher> include <abstractions/bus/org.kde.StatusNotifierWatcher>
include <abstractions/consoles> include <abstractions/consoles>
include <abstractions/dconf-write> include <abstractions/dconf-write>
include <abstractions/dri-common> include <abstractions/desktop>
include <abstractions/dri-enumerate>
include <abstractions/fontconfig-cache-read> include <abstractions/fontconfig-cache-read>
include <abstractions/fonts> include <abstractions/graphics>
include <abstractions/freedesktop.org>
include <abstractions/gtk>
include <abstractions/ibus> include <abstractions/ibus>
include <abstractions/mesa>
include <abstractions/nameservice-strict> include <abstractions/nameservice-strict>
include <abstractions/nvidia>
include <abstractions/openssl> include <abstractions/openssl>
include <abstractions/private-files-strict> include <abstractions/private-files-strict>
include <abstractions/qt5-compose-cache-write> include <abstractions/qt5-compose-cache-write>
include <abstractions/qt5-settings-write> include <abstractions/qt5-settings-write>
include <abstractions/qt5>
include <abstractions/ssl_certs> include <abstractions/ssl_certs>
include <abstractions/user-download-strict> include <abstractions/user-download-strict>
include <abstractions/wayland>
include <abstractions/X-strict>
signal send set=(term, kill) peer=qbittorrent//python3, signal send set=(term, kill) peer=qbittorrent//python3,
@ -82,21 +71,19 @@ profile qbittorrent @{exec_path} {
@{bin}/python3.@{int} rCx -> python, # For "search engine" @{bin}/python3.@{int} rCx -> python, # For "search engine"
# Allowed apps to open # Allowed apps to open
@{bin}/spacefm rPx,
@{bin}/smplayer rPx,
@{bin}/vlc rPx,
@{bin}/mpv rPx,
@{bin}/geany rPx,
@{bin}/viewnior rPUx,
@{bin}/qpdfview rPx,
@{bin}/ebook-viewer rPx, @{bin}/ebook-viewer rPx,
@{bin}/geany rPx,
@{bin}/mpv rPx,
@{bin}/nautilus rPx, @{bin}/nautilus rPx,
@{FIREFOX_BIN} rPx, @{bin}/qpdfview rPx,
@{bin}/smplayer rPx,
@{bin}/spacefm rPx,
@{bin}/viewnior rPUx,
@{bin}/vlc rPx,
@{browsers_path} rPx,
/usr/share/GeoIP/GeoIP.dat r, /usr/share/GeoIP/GeoIP.dat r,
/usr/share/gvfs/remote-volume-monitors/{,*} r, /usr/share/gvfs/remote-volume-monitors/{,*} r,
/usr/share/hwdata/*.ids r,
/usr/share/qt5ct/** r,
owner @{user_cache_dirs}/ rw, owner @{user_cache_dirs}/ rw,
owner @{user_cache_dirs}/#@{int} rw, owner @{user_cache_dirs}/#@{int} rw,

View file

@ -127,7 +127,7 @@ profile snapd @{exec_path} {
/tmp/read-file[0-9]*/{,**} rw, /tmp/read-file[0-9]*/{,**} rw,
/boot/ r, /boot/ r,
/boot/grub/grubenv r, /boot/grub/grubenv r,
/ r, / r,
/home/ r, /home/ r,

View file

@ -40,6 +40,7 @@ profile spice-vdagent @{exec_path} {
/etc/pipewire/client.conf r, /etc/pipewire/client.conf r,
/var/lib/gdm{3,}/.config/user-dirs.dirs r,
/var/lib/nscd/passwd r, /var/lib/nscd/passwd r,
owner @{user_config_dirs}/user-dirs.dirs r, owner @{user_config_dirs}/user-dirs.dirs r,

View file

@ -36,9 +36,9 @@ profile update-ca-certificates @{exec_path} {
@{bin}/wc rix, @{bin}/wc rix,
@{lib}/ca-certificates/update.d/ r, @{lib}/ca-certificates/update.d/ r,
@{lib}/ca-certificates/update.d/* rix, @{lib}/ca-certificates/update.d/* rix,
/etc/ca-certificates/update.d/ r, /etc/ca-certificates/update.d/ r,
/etc/ca-certificates/update.d/* rix, /etc/ca-certificates/update.d/* rix,
/usr/share/p11-kit/modules/{,*} r, /usr/share/p11-kit/modules/{,*} r,
@ -56,8 +56,6 @@ profile update-ca-certificates @{exec_path} {
/tmp/ r, /tmp/ r,
owner /tmp/ca-certificates{,.crt}.tmp.* rw, owner /tmp/ca-certificates{,.crt}.tmp.* rw,
@{PROC}/filesystems r,
/dev/tty rw, /dev/tty rw,
include if exists <local/update-ca-certificates> include if exists <local/update-ca-certificates>

View file

@ -38,7 +38,7 @@ profile wireplumber @{exec_path} {
/opt/intel/oneapi/{compiler,lib,mkl}/**.so* mr, /opt/intel/oneapi/{compiler,lib,mkl}/**.so* mr,
/usr/share/alsa-card-profile/{,**} r, /usr/share/alsa-card-profile/{,**} r,
/usr/share/spa-*/bluez[0-9]*/{,*} r, /usr/share/spa-*/bluez@{int}/{,*} r,
/usr/share/wireplumber/{,**} r, /usr/share/wireplumber/{,**} r,
/etc/machine-id r, /etc/machine-id r,