systemd-hostnamed.service 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # SPDX-License-Identifier: LGPL-2.1+
  2. #
  3. # This file is part of systemd.
  4. #
  5. # systemd is free software; you can redistribute it and/or modify it
  6. # under the terms of the GNU Lesser General Public License as published by
  7. # the Free Software Foundation; either version 2.1 of the License, or
  8. # (at your option) any later version.
  9. [Unit]
  10. Description=Hostname Service
  11. Documentation=man:systemd-hostnamed.service(8) man:hostname(5) man:machine-info(5)
  12. Documentation=https://www.freedesktop.org/wiki/Software/systemd/hostnamed
  13. [Service]
  14. BusName=org.freedesktop.hostname1
  15. CapabilityBoundingSet=CAP_SYS_ADMIN
  16. ExecStart=/lib/systemd/systemd-hostnamed
  17. IPAddressDeny=any
  18. LockPersonality=yes
  19. MemoryDenyWriteExecute=yes
  20. NoNewPrivileges=yes
  21. PrivateDevices=yes
  22. PrivateNetwork=yes
  23. PrivateTmp=yes
  24. ProtectControlGroups=yes
  25. ProtectHome=yes
  26. ProtectKernelModules=yes
  27. ProtectKernelTunables=yes
  28. ProtectKernelLogs=yes
  29. ProtectSystem=strict
  30. ReadWritePaths=/etc
  31. RestrictAddressFamilies=AF_UNIX
  32. RestrictNamespaces=yes
  33. RestrictRealtime=yes
  34. RestrictSUIDSGID=yes
  35. SystemCallArchitectures=native
  36. SystemCallErrorNumber=EPERM
  37. SystemCallFilter=@system-service sethostname
  38. WatchdogSec=3min