feat(profile): general update.

This commit is contained in:
Alexandre Pujol 2024-05-01 14:22:42 +01:00
parent 4d9ea026c7
commit db87c56f37
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
21 changed files with 72 additions and 14 deletions

View file

@ -0,0 +1,18 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = @{bin}/smbspool
profile smbspool @{exec_path} {
include <abstractions/base>
@{exec_path} mr,
/etc/papersize r,
include if exists <local/smbspool>
}

View file

@ -14,6 +14,7 @@ profile sudo @{exec_path} flags=(attach_disconnected) {
include <abstractions/app/sudo>
capability chown,
capability fowner,
capability mknod,
capability sys_ptrace,

View file

@ -47,6 +47,9 @@ profile udisksd @{exec_path} flags=(attach_disconnected) {
mount fstype={btrfs,ext*,vfat,exfat,iso9660,udf,ntfs3} /dev/mmcblk[0-9] -> @{MOUNTS}/*/,
mount fstype={btrfs,ext*,vfat,exfat,iso9660,udf,ntfs3} /dev/mmcblk[0-9]*p[0-9]* -> @{MOUNTS}/*/,
mount options=(rw move) -> @{MOUNTS}/,
mount options=(rw move) -> @{MOUNTS}/*/,
# Allow mounting on temporary mount point
mount -> @{run}/udisks2/temp-mount-*/,
mount / -> @{MOUNTS}/*/,

View file

@ -1,5 +1,6 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2024 Zane Zakraisek <zz@eng.utah.edu>
# Copyright (C) 2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
@ -24,5 +25,8 @@ profile whatis @{exec_path} {
owner @{HOME}/.manpath r,
owner @{user_share_dirs}/man/{,**/}{,whatis} r,
owner @{user_share_dirs}/man/{,**/}index.{bt,db,dir,pag} rk,
include if exists <local/whatis>
}

View file

@ -18,15 +18,18 @@ profile zpool @{exec_path} {
@{sh_path} rix,
/{usr/,}{local/,}lib/zfs-linux/zpool.d/* rix,
/usr/share/zfs/{,**} r,
/etc/hostid r,
/etc/zfs/*.cache rwk,
/tmp/tmp.* rw,
@{run}/blkid/blkid.tab rw,
@{run}/blkid/blkid.tab.old rwl,
@{run}/blkid/blkid.tab-@{rand6} rwl,
/tmp/tmp.* rw,
@{sys}/module/zfs/** r,
@{sys}/bus/pci/slots/ r,
@{sys}/bus/pci/slots/@{int}/address r,