diff --git a/apparmor.d/profiles-a-l/haveged b/apparmor.d/profiles-a-l/haveged new file mode 100644 index 00000000..cfe048fe --- /dev/null +++ b/apparmor.d/profiles-a-l/haveged @@ -0,0 +1,33 @@ +# apparmor.d - Full set of apparmor profiles +# Copyright (C) 2009-2012 Steve Kostecke ; +# 2011-2014 Jérémy Bobbio ; +# 2020 krathalan https://git.sr.ht/~krathalan/apparmor-profiles/ +# SPDX-License-Identifier: GPL-3.0-only + +# Version of program profiled: 1.9.14 + +abi , +include + +@{exec_path} = /{usr/,}bin/haveged +profile haveged @{exec_path} { + include + + # Required for ioctl RNDADDENTROPY + capability sys_admin, + + owner @{PROC}/@{pid}/status r, + + @{exec_path} mr, + + @{PROC}/sys/kernel/osrelease r, + @{PROC}/sys/kernel/random/poolsize r, + @{PROC}/sys/kernel/random/write_wakeup_threshold w, + /dev/random w, + + @{sys}/devices/system/cpu/ r, + @{sys}/devices/system/cpu/cpu*/cache/ r, + @{sys}/devices/system/cpu/cpu*/cache/index*/{type,size,level} r, + + include if exists +}