summaryrefslogtreecommitdiffstats
path: root/roles/lists/files/lib
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2016-05-12 11:34:36 +0200
committerGuilhem Moulin <guilhem@fripost.org>2016-05-12 11:34:36 +0200
commite51921b1242b40eefd16f29bcc408c6ac0df1619 (patch)
tree12f93d8d743d39fc9a4d1d6836d04eccf163b24f /roles/lists/files/lib
parent90d498034b891123350785a134402172de477f4f (diff)
Add hardening options to our systemd unit files.
Diffstat (limited to 'roles/lists/files/lib')
-rw-r--r--roles/lists/files/lib/systemd/system/wwsympa.service9
1 files changed, 9 insertions, 0 deletions
diff --git a/roles/lists/files/lib/systemd/system/wwsympa.service b/roles/lists/files/lib/systemd/system/wwsympa.service
index ea2a78f..b525145 100644
--- a/roles/lists/files/lib/systemd/system/wwsympa.service
+++ b/roles/lists/files/lib/systemd/system/wwsympa.service
@@ -10,5 +10,14 @@ User=sympa
Group=sympa
ExecStart=/usr/lib/cgi-bin/sympa/wwsympa.fcgi
+# Hardening
+NoNewPrivileges=yes
+PrivateDevices=yes
+ProtectHome=yes
+ProtectSystem=full
+ReadOnlyDirectories=/
+ReadWriteDirectories=-/var/lib/sympa
+ReadWriteDirectories=-/var/run/sympa
+
[Install]
WantedBy=multi-user.target