apparmor.d/apparmor.d/profiles-s-z/update-command-not-found
2022-06-05 22:47:37 +01:00

47 lines
1.2 KiB
Text

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2019-2021 Mikhail Morfikov
# Copyright (C) 2022 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /usr/share/command-not-found/cnf-update-db
@{exec_path} += /{usr/,}{s,}bin/update-command-not-found
@{exec_path} += /{usr/,}lib/cnf-update-db
profile update-command-not-found @{exec_path} {
include <abstractions/base>
include <abstractions/consoles>
include <abstractions/nameservice-strict>
include <abstractions/python>
@{exec_path} r,
/{usr/,}bin/python3.[0-9]* r,
/{usr/,}lib/ r,
/{usr/,}bin/dpkg rPx -> child-dpkg,
/{usr/,}lib/apt/apt-helper rix,
/usr/share/dpkg/cputable r,
/usr/share/dpkg/tupletable r,
/usr/share/command-not-found/{,**} r,
/etc/apt/apt.conf.d/{,*} r,
/etc/apt/apt.conf r,
/var/lib/command-not-found/ r,
/var/lib/command-not-found/commands.db* rwk,
/var/lib/apt/lists/ r,
/var/lib/apt/lists/*_Contents-* r,
/var/lib/apt/lists/*_Commands-* r,
owner @{PROC}/@{pid}/fd/ r,
# file_inherit
/var/log/cron-apt/temp w,
include if exists <local/update-command-not-found>
}