Page MenuHomePhabricator

old users not sysopable
Closed, ResolvedPublic

Description

Author: jasonr

Description:
If you are running a shared-login setup, then users who sign up on one site can
not be made sysops on a wiki other than the one they signed up for. The reason
is that the Makesysop.php script uses a left join statement to get the user's id
from the shared user table and their rights from the local user_rights table.
However, the user_rights table entry is made when the user signs up. So, only
one site will have a user_rights entry in it's table for the user. So, the
query turns up null, and any attempt to make the user a sysop results in a query
trying to add sysop rights to the user with id 0.

I've fixed my setup by splitting the join into two queries, so that I always
have the correct user id, regardless of what's in user_rights.


Version: 1.4.x
Severity: normal

Details

Reference
bz1180

Event Timeline

bzimport raised the priority of this task from to Normal.Nov 21 2014, 8:07 PM
bzimport set Reference to bz1180.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Dec 23 2004, 8:02 PM

jasonr wrote:

patch to allow sysoping of users

Here is a patch that makes it work, but I know it could be done better...

Attached:

brion added a comment.Dec 23 2004, 9:39 PM

It should have been a left _OUTER_ join. Fixed that for both name and ID modes.