From: Christian Hesse <[email protected]>
ProtectSystem=true mounts the /usr and /boot directories read-only.
ProtectHome=true makes the directories /home, /root and /run/user
inaccessible and empty for the process.
See systemd.exec(5) [0] for details.
v2: Replace ProtectSystem=strict with ProtectSystem=true. Some configurations
may want to write to /etc or the like.
[0] https://www.freedesktop.org/software/systemd/man/systemd.exec.html
Signed-off-by: Christian Hesse <[email protected]>
---
distro/systemd/[email protected] | 2 ++
distro/systemd/[email protected] | 2 ++
2 files changed, 4 insertions(+)
diff --git a/distro/systemd/[email protected]
b/distro/systemd/[email protected]
index 5618af3..b92f2fa 100644
--- a/distro/systemd/[email protected]
+++ b/distro/systemd/[email protected]
@@ -17,6 +17,8 @@ CapabilityBoundingSet=CAP_IPC_LOCK CAP_NET_ADMIN CAP_NET_RAW
CAP_SETGID CAP_SETU
LimitNPROC=10
DeviceAllow=/dev/null rw
DeviceAllow=/dev/net/tun rw
+ProtectSystem=true
+ProtectHome=true
[Install]
WantedBy=multi-user.target
diff --git a/distro/systemd/[email protected]
b/distro/systemd/[email protected]
index b9b4dba..535a79d 100644
--- a/distro/systemd/[email protected]
+++ b/distro/systemd/[email protected]
@@ -17,6 +17,8 @@ CapabilityBoundingSet=CAP_IPC_LOCK CAP_NET_ADMIN
CAP_NET_BIND_SERVICE CAP_NET_RA
LimitNPROC=10
DeviceAllow=/dev/null rw
DeviceAllow=/dev/net/tun rw
+ProtectSystem=true
+ProtectHome=true
[Install]
WantedBy=multi-user.target
--
2.11.0
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel