Commit 36fff59a authored by Max Kellermann's avatar Max Kellermann

client_file: always allow access if client uid equals mpd uid

parent 1e60a438
......@@ -39,6 +39,11 @@ client_allow_file(const struct client *client, const char *path_fs,
return false;
#else
const int uid = client_get_uid(client);
if (uid >= 0 && (uid_t)uid == geteuid())
/* always allow access if user runs his own MPD
instance */
return true;
if (uid <= 0) {
/* unauthenticated client */
g_set_error(error_r, ack_quark(), ACK_ERROR_PERMISSION,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment