mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2025-01-18 08:58:15 +01:00
feat(full): add some services profile.
This commit is contained in:
parent
dd767f13c0
commit
07e7810d15
2 changed files with 55 additions and 0 deletions
33
apparmor.d/groups/service/dmesg.service
Normal file
33
apparmor.d/groups/service/dmesg.service
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
# apparmor.d - Full set of apparmor profiles
|
||||||
|
# Copyright (C) 2023 Alexandre Pujol <alexandre@pujol.io>
|
||||||
|
# SPDX-License-Identifier: GPL-2.0-only
|
||||||
|
|
||||||
|
# Profile for a systemd service, it does not specify an attachment path because
|
||||||
|
# it is intended to be used only via "Px -> *.service" exec transitions from systemd
|
||||||
|
|
||||||
|
abi <abi/3.0>,
|
||||||
|
|
||||||
|
include <tunables/global>
|
||||||
|
|
||||||
|
profile dmesg.service {
|
||||||
|
include <abstractions/base>
|
||||||
|
|
||||||
|
@{bin}/savelog mr,
|
||||||
|
|
||||||
|
@{bin}/basename rix,
|
||||||
|
@{bin}/chmod rix,
|
||||||
|
@{bin}/date rix,
|
||||||
|
@{bin}/dirname rix,
|
||||||
|
@{bin}/gzip rix,
|
||||||
|
@{bin}/ln rix,
|
||||||
|
@{bin}/mv rix,
|
||||||
|
@{bin}/rm rix,
|
||||||
|
@{bin}/touch rix,
|
||||||
|
|
||||||
|
/var/log/ r,
|
||||||
|
/var/log/dmesg rw,
|
||||||
|
/var/log/dmesg.* rwl -> /var/log/dmesg,
|
||||||
|
|
||||||
|
include if exists <usr/dmesg.service.d>
|
||||||
|
include if exists <local/dmesg.service>
|
||||||
|
}
|
22
apparmor.d/groups/service/ldconfig.service
Normal file
22
apparmor.d/groups/service/ldconfig.service
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
# apparmor.d - Full set of apparmor profiles
|
||||||
|
# Copyright (C) 2023 Alexandre Pujol <alexandre@pujol.io>
|
||||||
|
# SPDX-License-Identifier: GPL-2.0-only
|
||||||
|
|
||||||
|
# Profile for a systemd service, it does not specify an attachment path because
|
||||||
|
# it is intended to be used only via "Px -> *.service" exec transitions from systemd
|
||||||
|
|
||||||
|
abi <abi/3.0>,
|
||||||
|
|
||||||
|
include <tunables/global>
|
||||||
|
|
||||||
|
profile ldconfig.service {
|
||||||
|
include <abstractions/base>
|
||||||
|
|
||||||
|
@{bin}/ldconfig mr,
|
||||||
|
@{lib}/ r,
|
||||||
|
|
||||||
|
/var/cache/ldconfig/{,**} rw,
|
||||||
|
|
||||||
|
include if exists <usr/ldconfig.service.d>
|
||||||
|
include if exists <local/ldconfig.service>
|
||||||
|
}
|
Loading…
Reference in a new issue