mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2025-01-30 14:55:15 +01:00
70 lines
1.7 KiB
Text
70 lines
1.7 KiB
Text
# apparmor.d - Full set of apparmor profiles
|
|
# Copyright (C) 2017-2021 Mikhail Morfikov
|
|
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
abi <abi/3.0>,
|
|
|
|
include <tunables/global>
|
|
|
|
@{exec_path} = /{usr/,}bin/fuseiso
|
|
profile fuseiso @{exec_path} {
|
|
include <abstractions/base>
|
|
include <abstractions/nameservice-strict>
|
|
|
|
@{exec_path} mr,
|
|
|
|
/{usr/,}bin/fusermount{,3} rCx -> fusermount,
|
|
|
|
# Where to mount ISO files
|
|
owner @{HOME}/*/ rw,
|
|
owner @{HOME}/*/*/ rw,
|
|
owner @{HOME}/.cache/**/ r,
|
|
|
|
# Be able to mount ISO images
|
|
mount fstype=fuse.fuseiso -> @{HOME}/*/,
|
|
mount fstype=fuse.fuseiso -> @{HOME}/*/*/,
|
|
mount fstype=fuse.fuseiso -> @{HOME}/.cache/**/,
|
|
|
|
# Image files to be mounted
|
|
owner @{HOME}/**.{iso,img,bin,mdf,nrg} rwk,
|
|
owner @{MOUNTS}/**.{iso,img,bin,mdf,nrg} rwk,
|
|
owner @{HOME}/**.{ISO,IMG,BIN,MDF,NRG} rwk,
|
|
owner @{MOUNTS}/**.{ISO,IMG,BIN,MDF,NRG} rwk,
|
|
|
|
owner @{HOME}/.mtab.fuseiso rwk,
|
|
owner @{HOME}/.mtab.fuseiso.new rw,
|
|
|
|
/dev/fuse rw,
|
|
|
|
|
|
profile fusermount {
|
|
include <abstractions/base>
|
|
include <abstractions/nameservice-strict>
|
|
|
|
# To mount anything:
|
|
capability sys_admin,
|
|
|
|
capability dac_read_search,
|
|
|
|
/{usr/,}bin/fusermount{,3} mr,
|
|
|
|
mount fstype={fuse,fuse.fuseiso} -> @{HOME}/*/,
|
|
mount fstype={fuse,fuse.fuseiso} -> @{HOME}/*/*/,
|
|
mount fstype={fuse,fuse.fuseiso} -> @{HOME}/.cache/**/,
|
|
|
|
/dev/fuse rw,
|
|
|
|
/etc/fuse.conf r,
|
|
|
|
@{PROC}/@{pid}/mounts r,
|
|
|
|
# Image files to be mounted
|
|
owner @{HOME}/**.{iso,img,bin,mdf,nrg} r,
|
|
owner @{MOUNTS}/**.{iso,img,bin,mdf,nrg} r,
|
|
owner @{HOME}/**.{ISO,IMG,BIN,MDF,NRG} r,
|
|
owner @{MOUNTS}/**.{ISO,IMG,BIN,MDF,NRG} r,
|
|
|
|
}
|
|
|
|
include if exists <local/fuseiso>
|
|
}
|