summaryrefslogtreecommitdiff
path: root/data/ModemManager.service.in
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2018-01-25 17:23:14 +0100
committerAleksander Morgado <aleksander@aleksander.es>2018-09-22 09:29:30 +0200
commitc490cc8e6ab262a7094a127f480bf0ac47f0c014 (patch)
tree2faefff7bab44f85d78c500325b6ac83848b209f /data/ModemManager.service.in
parent49b9e2b0191760b6cb7456630607c1b5f5efdbf4 (diff)
downloadModemManager-c490cc8e6ab262a7094a127f480bf0ac47f0c014.tar.gz
service: set User=root so that gio doesn't have to look into /etc/passwd
GVfs' libgvfsdbus.so GIo module, when automatically loaded, attempts to discover if there's a session D-Bus instance to use. It tries real hard to get the socket name it would use -- in absence of XDG_RUNTIME_DIR it decides to make it up with user's home directory. When HOME is unset too, it just tries to figure it out by looking into /etc/passwd. Which upsets SELinux that would better not see us looking into it. We trigger the load of the GIo modules, by using the GFile API to access the the ports in /dev. They're utterly uesless to us, but there doesn't seem to be a way to disable their load. Oh well. For now, let's just ensure HOME is set and the problematic path in glib is not taken. (cherry picked from commit cf3f3ffcd0da1ef5512bf4a2dce4e0e1861acbc7)
Diffstat (limited to 'data/ModemManager.service.in')
-rw-r--r--data/ModemManager.service.in1
1 files changed, 1 insertions, 0 deletions
diff --git a/data/ModemManager.service.in b/data/ModemManager.service.in
index 478677695..420d22b19 100644
--- a/data/ModemManager.service.in
+++ b/data/ModemManager.service.in
@@ -13,6 +13,7 @@ ProtectHome=true
PrivateTmp=true
RestrictAddressFamilies=AF_NETLINK AF_UNIX
NoNewPrivileges=true
+User=root
[Install]
WantedBy=multi-user.target