mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2025-01-18 17:08:09 +01:00
Add ZFS Event Daemon (#56)
This commit is contained in:
parent
eb6c7548f5
commit
081308db2f
2 changed files with 56 additions and 1 deletions
51
apparmor.d/profiles-s-z/zed
Normal file
51
apparmor.d/profiles-s-z/zed
Normal file
|
@ -0,0 +1,51 @@
|
||||||
|
# apparmor.d - Full set of apparmor profiles
|
||||||
|
# Copyright (C) 2022 Jeroen Rijken
|
||||||
|
# SPDX-License-Identifier: GPL-2.0-only
|
||||||
|
|
||||||
|
abi <abi/3.0>,
|
||||||
|
|
||||||
|
include <tunables/global>
|
||||||
|
|
||||||
|
@{exec_path} = /{usr/,}{local/,}{s,}bin/zed
|
||||||
|
profile zed @{exec_path} flags=(complain) {
|
||||||
|
include <abstractions/base>
|
||||||
|
include <abstractions/disks-read>
|
||||||
|
|
||||||
|
capability sys_admin,
|
||||||
|
|
||||||
|
network netlink raw,
|
||||||
|
|
||||||
|
@{exec_path} mr,
|
||||||
|
/{usr/,}bin/basename rix,
|
||||||
|
/{usr/,}bin/cat rix,
|
||||||
|
/{usr/,}bin/diff rix,
|
||||||
|
/{usr/,}bin/expr rix,
|
||||||
|
/{usr/,}bin/flock rix,
|
||||||
|
/{usr/,}bin/grep rix,
|
||||||
|
/{usr/,}bin/ls rix,
|
||||||
|
/{usr/,}bin/logger rix,
|
||||||
|
/{usr/,}bin/mawk rix,
|
||||||
|
/{usr/,}bin/rm rix,
|
||||||
|
/{usr/,}bin/realpath rix,
|
||||||
|
/{usr/,}bin/sort rix,
|
||||||
|
/{usr/,}{local/,}{s,}bin/zpool rPx,
|
||||||
|
/{usr/,}{local/,}{s,}bin/zfs rPx,
|
||||||
|
/{usr/,}{local/,}lib/zfs-linux/zed.d/*.sh rix,
|
||||||
|
|
||||||
|
/etc/zfs/zed.d/{,*} r,
|
||||||
|
/etc/zfs/zfs-list.cache/{,*} rwk,
|
||||||
|
|
||||||
|
@{run}/zed.pid rwkl,
|
||||||
|
@{run}/zed.state rwkl,
|
||||||
|
@{run}/zfs-list.cache@* rw,
|
||||||
|
|
||||||
|
@{PROC}/@{pids}/mounts r,
|
||||||
|
owner @{PROC}/@{pids}/fd/ r,
|
||||||
|
@{PROC}/@{pid}/task/@{tid}/comm rw,
|
||||||
|
|
||||||
|
@{sys}/bus/pci/slots/ r,
|
||||||
|
|
||||||
|
/dev/zfs rw,
|
||||||
|
|
||||||
|
include if exists <local/zed>
|
||||||
|
}
|
|
@ -12,10 +12,14 @@ profile zfs @{exec_path} flags=(complain) {
|
||||||
|
|
||||||
capability sys_admin,
|
capability sys_admin,
|
||||||
|
|
||||||
@{exec_path} r,
|
@{exec_path} mr,
|
||||||
|
|
||||||
|
/etc/zfs/zfs-list.cache/{,*} rwk,
|
||||||
|
|
||||||
@{PROC}/@{pids}/mounts r,
|
@{PROC}/@{pids}/mounts r,
|
||||||
|
|
||||||
|
@{run}/zfs-list.cache@* rw,
|
||||||
|
|
||||||
/dev/zfs rw,
|
/dev/zfs rw,
|
||||||
|
|
||||||
include if exists <local/zfs>
|
include if exists <local/zfs>
|
||||||
|
|
Loading…
Reference in a new issue