File harden_nut-monitor.service.patch of Package nut
Index: nut-2.8.0/scripts/systemd/nut-monitor.service.in
===================================================================
--- nut-2.8.0.orig/scripts/systemd/nut-monitor.service.in
+++ nut-2.8.0/scripts/systemd/nut-monitor.service.in
@@ -16,6 +16,17 @@ Wants=nut-server.service
PartOf=nut.target
[Service]
+# added automatically, for details please see
+# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort
+ProtectSystem=full
+ProtectHome=true
+ProtectHostname=true
+ProtectKernelTunables=true
+ProtectKernelModules=true
+ProtectKernelLogs=true
+ProtectControlGroups=true
+RestrictRealtime=true
+# end of automatic additions
EnvironmentFile=-@CONFPATH@/nut.conf
SyslogIdentifier=%N
ExecStart=@SBINDIR@/upsmon -F