2013-12-29 05:30:31 +01:00
|
|
|
[Unit]
|
|
|
|
Description=NSD DNS Server
|
|
|
|
After=syslog.target network.target
|
|
|
|
|
|
|
|
[Service]
|
2021-10-12 22:46:21 +02:00
|
|
|
Type=simple
|
|
|
|
PIDFile=/run/nsd/nsd.pid
|
|
|
|
ExecStart=/usr/sbin/nsd -d -c /etc/nsd/nsd.conf
|
|
|
|
ExecStopPost=/bin/rm -f /var/lib/nsd/xfrd.state
|
|
|
|
User=_nsd
|
|
|
|
Group=_nsd
|
|
|
|
|
2021-10-12 21:53:30 +02:00
|
|
|
# added automatically, for details please see
|
|
|
|
# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort
|
|
|
|
ProtectSystem=full
|
|
|
|
ProtectHome=true
|
|
|
|
PrivateDevices=true
|
|
|
|
ProtectHostname=true
|
|
|
|
ProtectClock=true
|
|
|
|
ProtectKernelTunables=true
|
|
|
|
ProtectKernelModules=true
|
|
|
|
ProtectKernelLogs=true
|
|
|
|
ProtectControlGroups=true
|
|
|
|
RestrictRealtime=true
|
2021-10-12 22:46:21 +02:00
|
|
|
# end of automatic additions
|
|
|
|
|
|
|
|
# even more hardening options
|
|
|
|
CapabilityBoundingSet=CAP_NET_BIND_SERVICE
|
|
|
|
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
2021-10-13 14:52:27 +02:00
|
|
|
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX AF_NETLINK
|
2021-10-12 22:46:21 +02:00
|
|
|
PrivateTmp=yes
|
|
|
|
NoNewPrivileges=yes
|
|
|
|
MountFlags=private
|
|
|
|
LockPersonality=yes
|
|
|
|
KeyringMode=private
|
|
|
|
RestrictNamespaces=yes
|
|
|
|
RestrictSUIDSGID=yes
|
|
|
|
DevicePolicy=closed
|
|
|
|
MemoryDenyWriteExecute=yes
|
|
|
|
SystemCallArchitectures=native
|
2021-11-13 23:46:24 +01:00
|
|
|
SystemCallFilter=~ @clock @cpu-emulation @debug @keyring @module @mount @raw-io @reboot @swap @obsolete @resources @pkey
|
2013-12-29 05:30:31 +01:00
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|