-
Notifications
You must be signed in to change notification settings - Fork 0
/
post-clock.service
47 lines (42 loc) · 1.14 KB
/
post-clock.service
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
[Unit]
Description=POST codes display clock
[Service]
ExecStart=/usr/local/bin/post-clock
Nice=10
# User and capabilities
DynamicUser=true
CapabilityBoundingSet=CAP_SYS_RAWIO
AmbientCapabilities=CAP_SYS_RAWIO
# Security
NoNewPrivileges=true
SecureBits=keep-caps keep-caps-locked
SecureBits=no-setuid-fixup no-setuid-fixup-locked
SecureBits=noroot noroot-locked
# Sandboxing
ProtectSystem=strict
ProtectHome=true
PrivateTmp=true
# PrivateDevices=true would remove CAP_SYS_RAWIO. Instead make /dev inaccessible:
InaccessiblePaths=/dev
PrivateNetwork=true
PrivateIPC=true
# PrivateUsers=true would remove capabilities in the host namespace, which we need.
ProtectHostname=true
ProtectClock=true
ProtectKernelTunables=true
ProtectKernelModules=true
ProtectKernelLogs=true
ProtectControlGroups=true
RestrictAddressFamilies=none
# RestrictFileSystems: no universal value to allow access to /etc/localtime.
RestrictNamespaces=true
LockPersonality=true
MemoryDenyWriteExecute=true
RestrictRealtime=true
RestrictSUIDSGID=true
RemoveIPC=true
SystemCallFilter=@system-service ioperm
SystemCallErrorNumber=EPERM
SystemCallArchitectures=native
[Install]
WantedBy=default.target