Accepting request 923291 from home:jsegitz:branches:systemdhardening:network:time

Automatic systemd hardening effort by the security team. This has not been tested. For details please see https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort

OBS-URL: https://build.opensuse.org/request/show/923291
OBS-URL: https://build.opensuse.org/package/show/network:time/linuxptp?expand=0&rev=22
This commit is contained in:
Martin Pluskal 2021-10-06 08:32:33 +00:00 committed by Git OBS Bridge
parent 60b66736e4
commit 7ad53cbd5b
3 changed files with 33 additions and 0 deletions

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Tue Oct 5 11:41:43 UTC 2021 - Johannes Segitz <jsegitz@suse.com>
- Added hardening to systemd service(s) (bsc#1181400). Modified:
* phc2sys.service
* ptp4l.service
-------------------------------------------------------------------
Tue Jul 06 08:06:16 UTC 2021 - jbohac@suse.com

View File

@ -3,6 +3,19 @@ Description=PTP: Synchronize two clocks
After=ntpdate.service
[Service]
# added automatically, for details please see
# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort
ProtectSystem=full
ProtectHome=true
PrivateDevices=true
ProtectHostname=true
ProtectKernelTunables=true
ProtectKernelModules=true
ProtectKernelLogs=true
ProtectControlGroups=true
RestrictRealtime=true
DeviceAllow=/dev/rtc
# end of automatic additions
Type=simple
EnvironmentFile=-/etc/sysconfig/phc2sys
ExecStart=/usr/sbin/phc2sys $OPTIONS

View File

@ -2,6 +2,19 @@
Description=PTP: Boundary/Ordinary Clock
[Service]
# added automatically, for details please see
# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort
ProtectSystem=full
ProtectHome=true
PrivateDevices=true
ProtectHostname=true
ProtectKernelTunables=true
ProtectKernelModules=true
ProtectKernelLogs=true
ProtectControlGroups=true
RestrictRealtime=true
DeviceAllow=/dev/rtc
# end of automatic additions
Type=simple
EnvironmentFile=-/etc/sysconfig/ptp4l
ExecStart=/usr/sbin/ptp4l $OPTIONS