apparmor.d/profiles/xdg-desktop-menu
2021-04-01 16:17:47 +01:00

47 lines
1.3 KiB
Plaintext

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2018-2021 Mikhail Morfikov
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}bin/xdg-desktop-menu
profile xdg-desktop-menu @{exec_path} flags=(complain) {
include <abstractions/base>
include <abstractions/nameservice-strict>
include <abstractions/consoles>
include <abstractions/deny-root-dir-access>
@{exec_path} r,
/{usr/,}bin/{,ba,da}sh rix,
/{usr/,}bin/mkdir rix,
/{usr/,}bin/sed rix,
/{usr/,}bin/cut rix,
/{usr/,}bin/basename rix,
/{usr/,}bin/rm rix,
/{usr/,}bin/cp rix,
/{usr/,}bin/cat rix,
/{usr/,}bin/touch rix,
/{usr/,}bin/gawk rix,
/{usr/,}bin/whoami rix,
/{usr/,}bin/mv rix,
/{usr/,}bin/{,e}grep rix,
/{usr/,}bin/readlink rix,
/{usr/,}bin/update-desktop-database rPx,
owner @{HOME}/.config/menus/applications-merged/xdg-desktop-menu-dummy.menu rw,
owner @{HOME}/.local/share/applications/chrome-*.desktop rw,
owner @{HOME}/.gnome/apps/chrome-*.desktop rw,
/usr/share/applications/*.desktop rw,
/usr/share/*/*.desktop r,
/usr/share/applications/defaults.list r,
/usr/share/applications/defaults.list.new w,
include if exists <local/xdg-desktop-menu>
}