mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-12-22 13:33:56 +03:00
tests: Add capability tests for ProtectKernelLogs
This commit is contained in:
parent
8470304018
commit
07cab0f72b
@ -109,6 +109,8 @@ test_data_files = '''
|
||||
test-execute/exec-privatetmp-no.service
|
||||
test-execute/exec-privatetmp-yes.service
|
||||
test-execute/exec-protecthome-tmpfs-vs-protectsystem-strict.service
|
||||
test-execute/exec-protectkernellogs-yes-capabilities.service
|
||||
test-execute/exec-protectkernellogs-no-capabilities.service
|
||||
test-execute/exec-protectkernelmodules-no-capabilities.service
|
||||
test-execute/exec-protectkernelmodules-yes-capabilities.service
|
||||
test-execute/exec-protectkernelmodules-yes-mount-propagation.service
|
||||
|
@ -0,0 +1,7 @@
|
||||
[Unit]
|
||||
Description=Test CAP_SYSLOG for ProtectKernelLogs=no
|
||||
|
||||
[Service]
|
||||
ProtectKernelLogs=no
|
||||
ExecStart=/bin/sh -x -c 'capsh --print | grep cap_syslog'
|
||||
Type=oneshot
|
@ -0,0 +1,7 @@
|
||||
[Unit]
|
||||
Description=Test CAP_SYSLOG for ProtectKernelLogs=yes
|
||||
|
||||
[Service]
|
||||
ProtectKernelLogs=yes
|
||||
ExecStart=/bin/sh -x -c '! capsh --print | grep cap_syslog'
|
||||
Type=oneshot
|
Loading…
Reference in New Issue
Block a user