Commit 35e306cc authored by Leigh B. Stoller's avatar Leigh B. Stoller

Fix up mounts command to make sure that groups are respected; we were

return mount specs for people in the project instead of the group.
Harmless, since the mounts would fail as long as exports_setup was
doing the right thing.
parent 609c547e
......@@ -1815,17 +1815,17 @@ domounts(int sock, struct in_addr ipaddr, char *rdata, int tcp)
res = mydb_query("select u.uid from users as u "
"left join group_membership as p on p.uid=u.uid "
"where'%s' and and "
"where'%s' and p.gid='%s' and "
" u.status='active'",
1, pid);
1, pid, gid);
res = mydb_query("select distinct u.uid from users as u "
"left join exppid_access as a "
" on a.exp_pid='%s' and a.exp_eid='%s' "
"left join group_membership as p on p.uid=u.uid "
"where (('%s' and or "
"where (('%s' and p.gid='%s') or "
" and u.status='active'",
1, pid, eid, pid);
1, pid, eid, pid, gid);
if (!res) {
syslog(LOG_ERR, "MOUNTS: %s: DB Error getting users!", pid);
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