apparmor.d -> profiles
This commit is contained in:
parent
c408a878b7
commit
e9b8e62fcd
726 changed files with 0 additions and 0 deletions
123
profiles/ucf
Normal file
123
profiles/ucf
Normal file
|
|
@ -0,0 +1,123 @@
|
|||
# vim:syntax=apparmor
|
||||
# ------------------------------------------------------------------
|
||||
#
|
||||
# Copyright (C) 2019-2021 Mikhail Morfikov
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of version 2 of the GNU General Public
|
||||
# License published by the Free Software Foundation.
|
||||
#
|
||||
# ------------------------------------------------------------------
|
||||
|
||||
abi <abi/3.0>,
|
||||
|
||||
include <tunables/global>
|
||||
|
||||
@{exec_path} = /{usr/,}bin/ucf
|
||||
profile ucf @{exec_path} flags=(complain) {
|
||||
include <abstractions/base>
|
||||
include <abstractions/consoles>
|
||||
|
||||
@{exec_path} r,
|
||||
/{usr/,}bin/{,ba,da}sh rix,
|
||||
|
||||
/{usr/,}bin/basename rix,
|
||||
/{usr/,}bin/seq rix,
|
||||
/{usr/,}bin/cp rix,
|
||||
/{usr/,}bin/mv rix,
|
||||
/{usr/,}bin/rm rix,
|
||||
/{usr/,}bin/{,e}grep rix,
|
||||
/{usr/,}bin/which rix,
|
||||
/{usr/,}bin/md5sum rix,
|
||||
/{usr/,}bin/sed rix,
|
||||
/{usr/,}bin/getopt rix,
|
||||
/{usr/,}bin/mkdir rix,
|
||||
/{usr/,}bin/cat rix,
|
||||
/{usr/,}bin/id rix,
|
||||
/{usr/,}bin/readlink rix,
|
||||
/{usr/,}bin/perl rix,
|
||||
/{usr/,}bin/gawk rix,
|
||||
/{usr/,}bin/tr rix,
|
||||
/{usr/,}bin/dirname rix,
|
||||
/{usr/,}bin/stat rix,
|
||||
|
||||
# Do not strip env to avoid errors like the following:
|
||||
# ERROR: ld.so: object 'libfakeroot-sysv.so' from LD_PRELOAD cannot be preloaded (cannot open
|
||||
# shared object file): ignored.
|
||||
/{usr/,}bin/dpkg-query rpx,
|
||||
#
|
||||
/{usr/,}bin/dpkg-divert rPx,
|
||||
|
||||
/{usr/,}bin/sensible-pager rCx -> pager,
|
||||
|
||||
# Think what to do about this (#FIXME#)
|
||||
/usr/share/debconf/frontend rPx,
|
||||
#/usr/share/debconf/frontend rCx -> frontend,
|
||||
|
||||
/etc/ucf.conf r,
|
||||
/var/lib/ucf/** rw,
|
||||
|
||||
owner /tmp/* rw,
|
||||
/etc/default/* rw,
|
||||
|
||||
# For md5sum
|
||||
/etc/** r,
|
||||
/usr/share/*/conffiles/* r,
|
||||
@{run}/** r,
|
||||
|
||||
|
||||
# For writing new config files
|
||||
/etc/** rw,
|
||||
|
||||
/usr/share/debconf/confmodule r,
|
||||
|
||||
# For shell pwd
|
||||
/ r,
|
||||
/root/ r,
|
||||
|
||||
|
||||
profile pager flags=(complain) {
|
||||
include <abstractions/base>
|
||||
include <abstractions/consoles>
|
||||
|
||||
/{usr/,}bin/ r,
|
||||
/{usr/,}bin/sensible-pager mr,
|
||||
|
||||
# For shell pwd
|
||||
/root/ r,
|
||||
|
||||
}
|
||||
|
||||
profile frontend flags=(complain) {
|
||||
include <abstractions/base>
|
||||
include <abstractions/consoles>
|
||||
include <abstractions/perl>
|
||||
include <abstractions/nameservice-strict>
|
||||
|
||||
/usr/share/debconf/frontend r,
|
||||
/{usr/,}bin/perl r,
|
||||
|
||||
/{usr/,}bin/ucf rPx,
|
||||
|
||||
/{usr/,}bin/{,ba,da}sh rix,
|
||||
/{usr/,}bin/stty rix,
|
||||
/{usr/,}bin/locale rix,
|
||||
|
||||
/etc/debconf.conf r,
|
||||
owner /var/cache/debconf/{config,passwords,templates}.dat{,-new,-old} rwk,
|
||||
|
||||
# The following is needed when debconf uses GUI frontends.
|
||||
include <abstractions/gtk>
|
||||
include <abstractions/fonts>
|
||||
include <abstractions/fontconfig-cache-read>
|
||||
include <abstractions/freedesktop.org>
|
||||
capability dac_read_search,
|
||||
/{usr/,}bin/lsb_release rPx -> child-lsb_release,
|
||||
/{usr/,}bin/hostname rix,
|
||||
owner @{PROC}/@{pid}/mounts r,
|
||||
@{HOME}/.Xauthority r,
|
||||
|
||||
}
|
||||
|
||||
include if exists <local/ucf>
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue