feat(profiles): add initial version of nmcli.

This commit is contained in:
Alexandre Pujol 2022-10-23 11:26:42 +01:00
parent 0168f8b13b
commit d6cd1af9c8
No known key found for this signature in database
GPG Key ID: C5469996F0DF68EC
2 changed files with 39 additions and 0 deletions

View File

@ -0,0 +1,38 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2022 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}bin/nmcli
profile nmcli @{exec_path} {
include <abstractions/base>
capability dac_read_search,
capability sys_nice,
@{exec_path} mr,
/{usr/,}bin/less rCx -> pager,
@{run}/udev/data/+pci* r,
@{run}/udev/data/n[0-9]* r,
@{sys}/devices/virtual/net/{,**} r,
@{sys}/devices/pci[0-9]*/**/net/*/{,**} r,
profile pager {
include <abstractions/base>
include <abstractions/consoles>
/{usr/,}bin/less mr,
owner @{HOME}/.lesshs* rw,
owner @{user_cache_dirs}/.lesshs* rw,
}
include if exists <local/nmcli>
}

View File

@ -120,6 +120,7 @@ needrestart-iucode-scan-versions complain
networkd-dispatcher complain networkd-dispatcher complain
nft complain nft complain
nmap complain nmap complain
nmcli complain
nullmailer-send complain nullmailer-send complain
packagekitd attach_disconnected,complain packagekitd attach_disconnected,complain
pass complain pass complain