mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
Ensure test:/// URIs get routed to the non-privileged libvirtd
* src/remote_internal.c: Ensure that all test:/// URIs are dealt with by the auto-started, per-user unprivileged libvirtd instances
This commit is contained in:
@@ -994,7 +994,8 @@ remoteOpen (virConnectPtr conn,
|
|||||||
conn->uri->scheme &&
|
conn->uri->scheme &&
|
||||||
((strchr(conn->uri->scheme, '+') == 0)||
|
((strchr(conn->uri->scheme, '+') == 0)||
|
||||||
(strstr(conn->uri->scheme, "+unix") != NULL)) &&
|
(strstr(conn->uri->scheme, "+unix") != NULL)) &&
|
||||||
STREQ(conn->uri->path, "/session") &&
|
(STREQ(conn->uri->path, "/session") ||
|
||||||
|
STRPREFIX(conn->uri->scheme, "test+")) &&
|
||||||
getuid() > 0) {
|
getuid() > 0) {
|
||||||
DEBUG0("Auto-spawn user daemon instance");
|
DEBUG0("Auto-spawn user daemon instance");
|
||||||
rflags |= VIR_DRV_OPEN_REMOTE_USER;
|
rflags |= VIR_DRV_OPEN_REMOTE_USER;
|
||||||
|
|||||||
Reference in New Issue
Block a user