How do I login as sysop?
Goto page 1, 2  Next
 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php|uber.leet Forum Index // How do I?
View previous topic :: View next topic  
Author Message
Llama



Joined: 28 Feb 2007
Posts: 1

PostPosted: Wed Feb 28, 2007 2:14 am    Post subject: How do I login as sysop? Reply with quote
Hi.
How could I login as sysop?
I do:
Code:

 select user_id, user_name, user_password from user limit 1;
+---------+-----------+----------------------------------+
| user_id | user_name | user_password                    |
+---------+-----------+----------------------------------+
|       1 | SYSop     | 19fd3aeec70565514291b66a706fe48d |
+---------+-----------+----------------------------------+


UPDATE user SET user_password =   md5(CONCAT('1-',md5('123'))) WHERE user_id=1;


The I try log in as 'SYSop' with password '123';

And login wails.
Anyway, I could log in with my phpBB account, but how to log in as wiki admin? Or there any way to tell mediawiki that some phpBB accounts are 'sysop' account in wiki?

Peace of config:

$wgGroupPermissions['*']['edit'] = false;

// Specify who may create new accounts.
$wgGroupPermissions['*']['createaccount'] = false;

// PHPBB User Database Plugin. (Requires MySQL Database)
require_once './extensions/Auth_phpbb.php';

$wgPHPBB_WikiGroupName = 'wiki'; // Name of your PHPBB group
// users need to be a member
// of to use the wiki. (i.e. wiki)

$wgPHPBB_UseWikiGroup = false; // This tells the Plugin to require
// a user to be a member of the above
// phpBB group. (ie. wiki) Setting
// this to false will let any phpBB
// user edit the wiki.

$wgPHPBB_UseExtDatabase = true; // This tells the plugin that the phpBB tables
// are in a different database then the wiki.
// The default settings is false.
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Tue Mar 06, 2007 9:39 am    Post subject: Reply with quote
Sorry I missed your post.

When I installed MW I made the account "King" the sysop account.
Next I create an account in phpBB named "King".
Next I install the plug-in.
Now when I log into MW using "King" as the username and the password from phpBB I get sysops access to MW.

This worked the last time I was messing around with sysops accounts.
Back to top
View user's profile Send private message
marcusbacus



Joined: 13 Feb 2007
Posts: 4

PostPosted: Fri Jan 09, 2009 9:40 pm    Post subject: Reply with quote
So it means that the username in MW I've used as a sysop when installing must have an account now in phpBB? If the sysop don't exist as user in phpBB if the account is created there after the install of the extension will it work or should the extension be deactivated, and it should be done as you said?

This kind of tip should have been added to the instructions, as one can easily lost his sysop permissions this way and get lost... or else there should be a way to keep the sysop account(s) installed out of the phpBB engine - sometimes there are needs to use 2 different accounts. Creating a new sysop manually in the database probably won't work either if it's not in the phpBB list of users.

Another annoyance is that I could login with my username in phpBB etc. etc. (so the install is OK I suppose), but I still couldn't edit pages even with the edit function opened to all phpBB users (did it first as a test setting it to "false" in that Wiki group bit), it says I need to have to be in the "Users" group of MW to edit (and this is why I noticed the sysop error, I tried to login as sysop to add my phpBB username to that group)... the extension should make MW somehow understand that the phpBB users should be already able to edit, and automatically include these in the Users group of MW if editing is enabled to all phpBB users and if users must be also part of that group in MW.

I suppose that with the restrited editing capabilities to phpBB groups (aka Wiki, etc.) the users will be already able to edit - I just didn't want to add my own phpBB username (I'm an admin in this forum) to another group, like the special "Wiki" group (already created, for the future use).
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Sun Jan 11, 2009 3:28 pm    Post subject: Reply with quote
I'll have to read this again. I got lost in the 3rd paragraph. I think you might be making an assumption about how MW handles groups. Let me think about it.
Back to top
View user's profile Send private message
marcusbacus



Joined: 13 Feb 2007
Posts: 4

PostPosted: Sun Jan 11, 2009 4:01 pm    Post subject: Reply with quote
OK let me get this straight then, there aren't assumptions, but errors.

1 - I had a sysop in MW, working fine, and no other users created.

2 - I installed the extension, and after that I can't login anymore with the sysop username I had created. I didn't create an user in phpBB before installing the extension. Is this a must do?

3 - I created an user, with the same username as the sysop used in the install of MW, in phpBB. It should give this user sysop permissions, right? It didn't.

4 - Let's say that the username was WikiSysop. I created it as it is (case sensitive) in phpBB. When I log in in MW, it appears as Wikisysop, therefore, as a different user. I can't login as WikiSysop, just as Wikisysop.

5 - All the connectivity between MW and my phpBB forum is working - all the phpBB users that should be able to access the Wiki are doing so. But those that could edit topics (those that are in the Wiki group...), can't. MW says they need to be included in some other group. Why?

6 - I will remove/disable this extension, create all the accounts in MW manually with the same usernames as people that have already usernames in my forum that will be the editing team, give sysop permissions to those that will be sysops and then I'll try to reinstall the extension again.

What I said beside the error reports is that the instructions that a "clone" of the sysop should be created first in phpBB should be included in the installation details, because, as I've experienced, creating it afterwards doesn't work, mostly if it needs to be CaSeSeNsItIvE for better security.
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Thu Jan 15, 2009 9:13 am    Post subject: Reply with quote
Case sensitivity for your username wont offer you any security protections. MW lists all the users under special pages.

http://en.wikipedia.org/wiki/Special:GlobalUsers
http://en.wikipedia.org/wiki/Special:ListUsers

phpBB3 uses case folding for it's usernames. The case folded username is stored in username_clean.

Take a look at the method getCanonicalName() in Auth_phpBB. In there I take the username supplied, case fold it, query the database for the clean username, ucfirst the clean username.

You could try changing.

Code:
$fstrMySQLQuery = sprintf("SELECT `username_clean`


to

Code:
$fstrMySQLQuery = sprintf("SELECT `username` AS `username_clean`




Quote:
5 - All the connectivity between MW and my phpBB forum is working - all the phpBB users that should be able to access the Wiki are doing so. But those that could edit topics (those that are in the Wiki group...), can't. MW says they need to be included in some other group. Why?


Maybe its a problem with the casing where the correct user accounts are not being linked.

The only permission changed I make in MW is in LocalSettings.php where I say a user has to be logged into the Wiki to make edits. I then control who can login from the "Wiki" group in phpBB.
Back to top
View user's profile Send private message
joshcryer



Joined: 20 Jan 2009
Posts: 4

PostPosted: Tue Jan 20, 2009 7:44 am    Post subject: Reply with quote
I have this same problem... I create a new version of mediawiki using my username "Josh Cryer," and on my phpBB install my username is "Josh Cryer."

When I try to log in with my phpBB password I get:

You need a phpBB account to login.
Click here to create an account.


I have:

$wgGroupPermissions['Wiki']['userrights'] = true;
$wgAddGroups['sysop'] = array( 'Wiki' );

And I added "Josh Cryer" to usergroup "Wiki" in the options.

Wish I could figure this one out. Smile
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Tue Jan 20, 2009 3:46 pm    Post subject: Reply with quote
You could try and same fix.

http://uber.leetphp.com/forums/viewtopic.php?p=853&sid=2274c2663dc375bed4db862c41bc0824#853
Back to top
View user's profile Send private message
joshcryer



Joined: 20 Jan 2009
Posts: 4

PostPosted: Wed Jan 21, 2009 12:05 am    Post subject: Reply with quote
I tried that. I'm going to try using a random nickname as sysop and then de-sysop it after giving my nickname sysop. We'll see if it works.
Back to top
View user's profile Send private message
joshcryer



Joined: 20 Jan 2009
Posts: 4

PostPosted: Wed Jan 21, 2009 2:41 am    Post subject: Reply with quote
Didn't work, could not log in as WikiSysop with extension installed. Am I setting up the 'wiki' group properly?

If I set "$wgAuth_Config['UseWikiGroup'] = false;" (it was true before), then I try logging in with Josh Cryer, it does work. I think I may be getting the group thing set up wrong.
Back to top
View user's profile Send private message
joshcryer



Joined: 20 Jan 2009
Posts: 4

PostPosted: Wed Jan 21, 2009 2:58 am    Post subject: Reply with quote
OK I figured it out. I wanted *only* phpBB users to be able to edit/post, and I was doing it the 'group' way.

However, I saw this:

// This requires a user be logged into the wiki to make changes.
$wgGroupPermissions['*']['edit'] = false;

// Specify who may create new accounts.
$wgGroupPermissions['*']['createaccount'] = false;

Works great!

Thank you root!
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Thu Jan 22, 2009 3:29 pm    Post subject: Reply with quote
Glad you figured it out.
Back to top
View user's profile Send private message
Kantar



Joined: 23 Jan 2009
Posts: 1

PostPosted: Fri Jan 23, 2009 4:24 pm    Post subject: Reply with quote
I had a similar issue with the MW user from setup "Kantar (Sysop, Bureaucrat)" and my phpBB3 user, "kantar" not having the same permissions.

I went into the DB in the wikiuser table to see that the MW user was user #1, and the phpBB3 user was #2 in the list.

Checking the wikiuser_groups table, only user 1 was granted Sysop and Bureaucrat permissions. I used phpMyAdmin to insert a row for user #2 with sysop and another with Bureaucrat permissions.

Now I can log in with my phpBB3 user and have the full permissions of a Sysop instead of a normal "user."
Back to top
View user's profile Send private message
DYSW



Joined: 26 Jan 2009
Posts: 6
Location: DK

PostPosted: Thu Feb 05, 2009 2:05 pm    Post subject: test Reply with quote
root wrote:
Sorry I missed your post.

When I installed MW I made the account "King" the sysop account.
Next I create an account in phpBB named "King".
Next I install the plug-in.
Now when I log into MW using "King" as the username and the password from phpBB I get sysops access to MW.

This worked the last time I was messing around with sysops accounts.


Hey root. I also have this problem. I did what you mentioned above. Worked fine. but the wikiadmin user has no sysop rights. if i login with the sysop name "wikiadmin" that i created MW with i cannot see special pages > Block user or when i click "User rights management" i just get forwarded as a normal user. No Enter a username like a sysop gets. But this user is the only one in the wiki database and no users besides "wikiadmin" have been added to the wiki group on phpbb. This makes little sense. No sysop access. How can i fix this ?

Kantar seem to have a solution here. But i cannot find out where to edit the database. there doesnt seems to be a setting where i can choose what group the users are in.

Kantar wrote:
I had a similar issue with the MW user from setup "Kantar (Sysop, Bureaucrat)" and my phpBB3 user, "kantar" not having the same permissions.

I went into the DB in the wikiuser table to see that the MW user was user #1, and the phpBB3 user was #2 in the list.

Checking the wikiuser_groups table, only user 1 was granted Sysop and Bureaucrat permissions. I used phpMyAdmin to insert a row for user #2 with sysop and another with Bureaucrat permissions.

Now I can log in with my phpBB3 user and have the full permissions of a Sysop instead of a normal "user."


root wrote:
Case sensitivity for your username wont offer you any security protections. MW lists all the users under special pages.

http://en.wikipedia.org/wiki/Special:GlobalUsers
http://en.wikipedia.org/wiki/Special:ListUsers

phpBB3 uses case folding for it's usernames. The case folded username is stored in username_clean.

Take a look at the method getCanonicalName() in Auth_phpBB. In there I take the username supplied, case fold it, query the database for the clean username, ucfirst the clean username.

You could try changing.

Code:
$fstrMySQLQuery = sprintf("SELECT `username_clean`


to

Code:
$fstrMySQLQuery = sprintf("SELECT `username` AS `username_clean`




Quote:
5 - All the connectivity between MW and my phpBB forum is working - all the phpBB users that should be able to access the Wiki are doing so. But those that could edit topics (those that are in the Wiki group...), can't. MW says they need to be included in some other group. Why?


Maybe its a problem with the casing where the correct user accounts are not being linked.

The only permission changed I make in MW is in LocalSettings.php where I say a user has to be logged into the Wiki to make edits. I then control who can login from the "Wiki" group in phpBB.


Did a search for this and there are multipli finds. What are the correct one ?

Thx <<<
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Thu Feb 05, 2009 10:43 pm    Post subject: Re: test Reply with quote
DYSW wrote:
Did a search for this and there are multipli finds. What are the correct one ?

Thx <<<


root wrote:
Take a look at the method getCanonicalName()
Back to top
View user's profile Send private message
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php|uber.leet Forum Index // How do I? All times are GMT - 8 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

alexisBlue v1.2 // Theme Created By: Andrew Charron and Web Hosting Bluebook
Powered by phpBB © 2001, 2002 phpBB Group