apparmor.d/apparmor.d/profiles-s-z/usbguard
2024-02-26 21:10:53 +00:00

35 lines
931 B
Text

# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2018-2021 Mikhail Morfikov
# Copyright (C) 2021-2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = @{bin}/usbguard
profile usbguard @{exec_path} {
include <abstractions/base>
include <abstractions/consoles>
include <abstractions/devices-usb>
capability chown,
capability fowner,
capability dac_override,
# Needed to create policy (usbguard generate-policy)
network netlink dgram,
@{exec_path} mr,
/etc/usbguard/*.conf rw,
/etc/usbguard/IPCAccessControl.d/{,*} rw,
/dev/shm/qb-usbguard-{request,response,event}-@{int}-@{int}-@{int}-{header,data} rw,
/dev/shm/qb-@{int}-@{int}-@{int}-*/qb-{request,response,event}-usbguard-{header,data} rw,
# For "usbguard generate-policy"
@{sys}/devices/@{pci}/uevent r,
include if exists <local/usbguard>
}