69 lines
1.6 KiB
Text
69 lines
1.6 KiB
Text
# apparmor.d - Full set of apparmor profiles
|
|
# Copyright (C) 2021 Mikhail Morfikov
|
|
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
abi <abi/3.0>,
|
|
|
|
include <tunables/global>
|
|
|
|
@{exec_path} = /{usr/,}bin/utox
|
|
profile utox @{exec_path} {
|
|
include <abstractions/base>
|
|
include <abstractions/dconf-write>
|
|
include <abstractions/gtk>
|
|
include <abstractions/fonts>
|
|
include <abstractions/fontconfig-cache-read>
|
|
include <abstractions/freedesktop.org>
|
|
include <abstractions/user-download-strict>
|
|
include <abstractions/nameservice-strict>
|
|
include <abstractions/audio>
|
|
include <abstractions/video>
|
|
|
|
network inet dgram,
|
|
network inet6 dgram,
|
|
network inet stream,
|
|
network inet6 stream,
|
|
network netlink raw,
|
|
|
|
@{exec_path} mr,
|
|
|
|
/{usr/,}bin/xdg-open rCx -> open,
|
|
|
|
owner @{HOME}/ r,
|
|
owner @{user_config_dirs}/tox/ rw,
|
|
owner @{user_config_dirs}/tox/** rw,
|
|
|
|
/var/lib/dbus/machine-id r,
|
|
/etc/machine-id r,
|
|
|
|
deny owner @{PROC}/@{pid}/cmdline r,
|
|
|
|
profile open {
|
|
include <abstractions/base>
|
|
include <abstractions/xdg-open>
|
|
|
|
/{usr/,}bin/xdg-open mr,
|
|
|
|
/{usr/,}bin/{,ba,da}sh rix,
|
|
/{usr/,}bin/{m,g,}awk rix,
|
|
/{usr/,}bin/readlink rix,
|
|
/{usr/,}bin/basename rix,
|
|
|
|
owner @{HOME}/ r,
|
|
|
|
owner @{run}/user/@{uid}/ r,
|
|
|
|
# Allowed apps to open
|
|
/{usr/,}lib/firefox/firefox rPUx,
|
|
/{usr/,}bin/viewnior rPUx,
|
|
|
|
# file_inherit
|
|
owner @{HOME}/.xsession-errors w,
|
|
owner @{user_config_dirs}/tox/[0-9A-F].ftinfo w,
|
|
owner @{user_config_dirs}/tox/[0-9A-F].ftoutfo w,
|
|
deny /dev/video[0-9]* rw,
|
|
|
|
}
|
|
|
|
include if exists <local/utox>
|
|
}
|