core: introduce ProtectProc= and ProcSubset= to expose hidepid= and subset= procfs mount options

Kernel 5.8 gained a hidepid= implementation that is truly per procfs,
which allows us to mount a distinct once into every unit, with
individual hidepid= settings. Let's expose this via two new settings:
ProtectProc= (wrapping hidpid=) and ProcSubset= (wrapping subset=).

Replaces: #11670
This commit is contained in:
Lennart Poettering
2020-08-24 20:11:02 +02:00
parent df6b900a1b
commit 4e39995371
12 changed files with 131 additions and 19 deletions
+3
View File
@@ -260,6 +260,9 @@ struct ExecContext {
char *log_namespace;
ProtectProc protect_proc; /* hidepid= */
ProcSubset proc_subset; /* subset= */
bool private_tmp;
bool private_network;
bool private_devices;