core: allow uid 0 to activate user connections

Previously, uid 0 was not permitted to activate user connections,
but in some cases this is desired.
This commit is contained in:
Dan Williams
2009-02-10 06:31:50 -05:00
parent 0bc29fe9d3
commit 555dfd35e6

View File

@@ -2091,6 +2091,14 @@ is_user_request_authorized (NMManager *manager,
goto out;
}
/* Let root activate anything.
* FIXME: use a PolicyKit permission instead
*/
if (0 == sender_uid) {
success = TRUE;
goto out;
}
service_name = dbus_g_proxy_get_bus_name (priv->user_proxy);
if (!service_name) {
g_set_error (error, NM_MANAGER_ERROR,