feat(profiles): add software-properties-dbus.

This commit is contained in:
Alexandre Pujol 2022-07-19 00:03:01 +01:00
parent 5b01f7963b
commit f4dd2745d1
No known key found for this signature in database
GPG Key ID: C5469996F0DF68EC

View File

@ -0,0 +1,36 @@
# apparmor.d - Full set of apparmor profiles
# 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/,}lib/software-properties/software-properties-dbus
profile software-properties-dbus @{exec_path} {
include <abstractions/base>
include <abstractions/apt-common>
include <abstractions/python>
include <abstractions/nameservice-strict>
include <abstractions/dbus-strict>
dbus bind bus=system
name=com.ubuntu.SoftwareProperties,
@{exec_path} mr,
/{usr/,}bin/python3.[0-9]* rix,
/{usr/,}bin/env rix,
/{usr/,}bin/lsb_release rPx -> lsb_release,
/usr/share/python-apt/{,**} r,
/usr/share/distro-info/*.csv r,
/usr/share/xml/iso-codes/{,**} r,
owner /tmp/[a-z0-9]* rw,
owner /tmp/tmp*/{,apt.conf} rw,
owner @{PROC}/@{pid}/fd/ r,
include if exists <local/software-properties-dbus>
}