apparmor.d/profiles/dpkg-architecture
2021-04-01 16:02:59 +01:00

47 lines
1 KiB
Text

# vim:syntax=apparmor
# ------------------------------------------------------------------
#
# Copyright (C) 2020-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/dpkg-architecture
profile dpkg-architecture @{exec_path} {
include <abstractions/base>
include <abstractions/perl>
@{exec_path} r,
/usr/bin/perl r,
/{usr/,}bin/{,@{multiarch}-}gcc-[0-9]* rix,
/{usr/,}bin/ccache rCx -> ccache,
/{usr/,}bin/dpkg rPx -> child-dpkg,
/usr/share/dpkg/** r,
# file_inherit
owner /tmp/* rw,
profile ccache {
include <abstractions/base>
/{usr/,}bin/ccache mr,
/{usr/,}bin/{,@{multiarch}-}gcc-[0-9]* rix,
/media/ccache/*/** rw,
}
include if exists <local/dpkg-architecture>
}