2020-09-12 17:19:23 +02:00
|
|
|
# vim:syntax=apparmor
|
|
|
|
# ------------------------------------------------------------------
|
|
|
|
#
|
|
|
|
# Copyright (C) 2020 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.
|
|
|
|
#
|
|
|
|
# ------------------------------------------------------------------
|
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
abi <abi/3.0>,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
include <tunables/global>
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
@{exec_path} = /{usr/,}bin/openbox
|
|
|
|
profile openbox @{exec_path} {
|
2020-12-10 22:33:39 +01:00
|
|
|
include <abstractions/base>
|
|
|
|
include <abstractions/fonts>
|
|
|
|
include <abstractions/fontconfig-cache-read>
|
|
|
|
include <abstractions/freedesktop.org>
|
|
|
|
include <abstractions/nameservice-strict>
|
|
|
|
include <abstractions/deny-root-dir-access>
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
signal (send) set=(term, kill),
|
|
|
|
|
|
|
|
@{exec_path} mr,
|
|
|
|
|
|
|
|
/{usr/,}lib/@{multiarch}/openbox-autostart rCx -> autostart,
|
|
|
|
|
|
|
|
# Apps allowed to run
|
|
|
|
/{usr/,}sbin/* rPUx,
|
|
|
|
/{usr/,}bin/* rPUx,
|
|
|
|
/usr/libexec/* rPUx,
|
|
|
|
|
|
|
|
/usr/share/themes/*/openbox-3/themerc r,
|
|
|
|
|
|
|
|
/etc/xdg/openbox/* r,
|
|
|
|
|
|
|
|
owner @{HOME}/ r,
|
|
|
|
owner @{HOME}/.config/openbox/* r,
|
|
|
|
|
|
|
|
owner @{HOME}/.config/obmenu-generator/icons/[0-9a-f]*.png r,
|
|
|
|
|
|
|
|
owner @{HOME}/.cache/ rw,
|
|
|
|
owner @{HOME}/.cache/openbox/ rw,
|
|
|
|
owner @{HOME}/.cache/openbox/openbox.log rw,
|
|
|
|
|
|
|
|
owner @{HOME}/.Xauthority r,
|
|
|
|
|
|
|
|
owner @{PROC}/@{pid}/fd/ r,
|
|
|
|
|
|
|
|
# file_inherit
|
|
|
|
owner /dev/tty[0-9]* rw,
|
|
|
|
owner @{HOME}/.xsession-errors w,
|
|
|
|
|
|
|
|
|
|
|
|
profile autostart {
|
2020-12-10 22:33:39 +01:00
|
|
|
include <abstractions/base>
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
/{usr/,}lib/@{multiarch}/openbox-autostart mr,
|
|
|
|
/{usr/,}lib/@{multiarch}/openbox-xdg-autostart rix,
|
|
|
|
|
2020-12-09 10:30:52 +01:00
|
|
|
/{usr/,}bin/{,ba,da}sh rix,
|
|
|
|
/{usr/,}bin/which rix,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
# Apps allowed to run
|
|
|
|
/{usr/,}bin/* rPUx,
|
|
|
|
/usr/libexec/* rPUx,
|
|
|
|
/{usr/,}lib/@{multiarch}/xfce4/*/* rPUx,
|
|
|
|
/{usr/,}lib/@{multiarch}/polkit-mate/polkit-mate-authentication-agent-1 rPUx,
|
|
|
|
|
|
|
|
/usr/local/lib/python*/dist-packages/ r,
|
|
|
|
|
2020-12-09 10:30:52 +01:00
|
|
|
owner @{HOME}/ r,
|
2020-09-12 17:19:23 +02:00
|
|
|
owner @{HOME}/.config/openbox/autostart r,
|
|
|
|
owner @{HOME}/.config/autostart/{,*} r,
|
2020-12-09 10:30:52 +01:00
|
|
|
/etc/xdg/openbox/autostart r,
|
2020-09-12 17:19:23 +02:00
|
|
|
/etc/xdg/autostart/{,*} r,
|
|
|
|
|
|
|
|
# file_inherit
|
|
|
|
owner @{HOME}/.xsession-errors w,
|
2020-09-12 17:46:51 +02:00
|
|
|
owner /dev/tty[0-9]* rw,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
include if exists <local/openbox_autostart>
|
2020-09-12 17:19:23 +02:00
|
|
|
}
|
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
include if exists <local/openbox>
|
2020-09-12 17:19:23 +02:00
|
|
|
}
|