The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
MediaWiki/vBulletin Single Sign-On Details »» | |||||||||||||||||||||||||
Overview:
This hack provides single sign-on capability for MediaWiki using your vBulletin users. You must ensure your cookie path in Admin CP is set to '/' for this to work. Also, I have not tested this if your wiki and your forums are on different subdomains - but as long as your have your cookie domain set properly it *should* work. This is not a user bridge - it is a complete single sign-on using your vBulletin user repository. The install process has been extremely simplified in version 2.x of this product. You only have to edit LocalSettings.php, import a product, and change a setting in your Admin Control Panel. It's been completely packaged as a vBulletin product - unlike the previous hacked up version, heh. I didn't originally plan to release this so I designed it so it worked - not so it could be redistributed. I searched high and low for a functional MediaWiki bridge - almost bought NuHIT's product, and then realized it had been abandoned for over a year. This hack no longer requires an edit to class_core.php. I'll do my best to support it, but I can make no promises. This thread is for discussion of this mod on vB 3.7.x. For vB 3.8.x, please use the MediaWiki/vBulletin Single Sign-On 3.8 thread Demo of plugin in action: MyMMOGames - Multiplayer Gaming and Media Community Also, if you use memcached - ensure you do not cache sessions. If you do, restart it at least once a week. If you don't, you'll end up with invalid session errors out of MediaWiki. Requirements: MediaWiki Version: 1.11.0-1.14.0 vBulletin Version: 3.6.9-3.8.2 Features: - Provides single sign on capability between vBulletin and Mediawiki. vBulletin user repository is used - Configurable sysop/bureaucrat groups - Configurable disallowed user groups - Configurable "Who's Online" display - Counts users viewing wiki in vBulletin's "Who's Online" Installation/Upgrade: Please read the included "readme.txt" file in the "docs (do not upload)" folder. Options: Admin Control Panel->vBulletin Options->MMOG Wiki Options Change Log: 1.0.0.0 - Sep 18, 2008 - Initial Release 1.0.3.0 - Sep 29, 2008 - Bugfix: Incorrect redirects for login/logout 2.0.0.0 - Sep 30, 2008 - Feature: Streamlined installation procedure - Feature: Wiki path set in ACP - Bugfix: Forum paths no longer hardcoded 2.1.0 - Oct 4, 2008 - Feature: ACP option to use MediaWiki Short URLs - Feature: ACP option to set sysop groups - Feature: ACP option to set bureaucrat groups - Feature: ACP option to disallow login to certain groups - Feature: ACP option to change WOL display text 2.2.0 - May 1, 2005 - Bugfix: Users are not logged out when logging out of the forum - Bugfix: No longer requires modification to class_core.php - Feature: Mediawiki 1.13.0+ supported (verified on 1.14.0 also) If you like it, please click "mark as installed" The more people that use this, the more time I will make to try and support/update it. Been pulling your hair out looking for this as long as I have? Nominate it for Mod of the Month =] AuthPlugin was inspired by and modified from this existing MediaWiki Extension: http://www.mediawiki.org/wiki/Extension:QISSingleSignOn Show Your Support
|
Comments |
#152
|
|||
|
|||
I did all you said but still have the same problem... Are you sure it works 100%? Please check the following:
1. login from vB -> check at wiki 2. logout from wiki -> go back and see if inside wiki really logged out 3. login from Wiki -> check at vB and wiki If it works for you I'm really curious what vB changed from 3.72 to 3.74 ... Bruno |
#153
|
||||
|
||||
OK -- I'm really really confused as to where to go from here as this thread has jumped all over and I can't figure out the good information from the bad information.
What I've done so far is to follow the instruction in the upload: Code:
STEP 1: Upload the contents of the "upload" directory into your wiki root directory. Edit LocalSettings.php find this line: require_once( "$IP/includes/DefaultSettings.php" ); After it, add these two lines: define( VB_SYSTEM_PATH, '/var/www/html/forum' ); require_once( "$IP/includes/AuthPlugin_vBSSO.php" ); VB_SYSTEM_PATH should be the full filesystem path to your vBulletin installation. If you don't know the full path, change to your forum home directpry and type pwd in a shell. It will print the current directory. Ensure you do not add a trailing slash to VB_SYSTEM_PATH! You no longer have to edit anything in AuthPlugin_vBSSO.php or Userlogin.php If you have anything in LocalSettings for $wgGroupPermissions['*']['createaccount'], change all instances of 'createaccount' to false. If you don't have anything in your LocalSettings.php for 'createaccount', add this line after the two you just added: $wgGroupPermissions['*']['createaccount'] = false; This is important so that new users create a forum account instead of a wiki account. If they create a wiki account by mistake, they will not be able to log in. STEP 2: Edit class_core.php (found in <forumhome>/includes). Why? vBulletin will mangle a security token needed by MediaWiki. If you do not make this change, your users will not be able to edit your wiki. It's really simple and it's worked across vB 3.6.9, 3.7.1, and 3.7.3. In class_core.php, search for this block of code: // reverse the effects of magic quotes if necessary if (function_exists('get_magic_quotes_gpc') AND get_magic_quotes_gpc()) { $this->stripslashes_deep($_REQUEST); // needed for some reason (at least on php5 - not tested on php4) $this->stripslashes_deep($_GET); $this->stripslashes_deep($_POST); $this->stripslashes_deep($_COOKIE); if (is_array($_FILES)) { foreach ($_FILES AS $key => $val) { $_FILES["$key"]['tmp_name'] = str_replace('\\', '\\\\', $val['tmp_name']); } $this->stripslashes_deep($_FILES); } } Replace it with this: // reverse the effects of magic quotes if necessary if (function_exists('get_magic_quotes_gpc') AND get_magic_quotes_gpc()) { if ( THIS_SCRIPT != 'wiki' ) { // MMOG Wiki hack $this->stripslashes_deep($_REQUEST); // needed for some reason (at least on php5 - not tested on php4) $this->stripslashes_deep($_GET); $this->stripslashes_deep($_POST); $this->stripslashes_deep($_COOKIE); if (is_array($_FILES)) { foreach ($_FILES AS $key => $val) { $_FILES["$key"]['tmp_name'] = str_replace('\\', '\\\\', $val['tmp_name']); } $this->stripslashes_deep($_FILES); } } } STEP 3: Import the product product-mmog_wiki.xml via your Admin CP. This is the hack that shows the users in "Who's Online" instead of "Unknown Location" and also configures your login/wiki paths. Go to your vBulletin Options and look for MMOG Wiki Options. Change "Wiki Path" to the URL path of your wiki. If your wiki is on a different subdomain, you need to put the full URL of your wiki path minus the trailing slash. Otherwise, just a relative directory is fine. So what do I need to do to get this to work? 1. replace modified class_core.php back with the original unmodified version? 2. Edited the AuthPlugin_vBSSO.php file from: $wgHooks[AutoAuthenticate ][] = 'vBSSOAutoAuth'; to $wgHooks['UserLoadFromSession'][] = 'vBSSOAutoAuth'; 3. edited User.php as stated in Post #143 (which mediawiki or vbulletin?) 4. Do I make any changes in my LocalSettings.php -- beyond what I did in the instructions? Am I missing anything on what I need to do to take this from where doing everything in the readme.txt to getting this to work? |
#154
|
|||
|
|||
Which Versions do you use?
|
#155
|
||||
|
||||
Vb 3.74.1
Mw 1.13.2 |
#156
|
|||
|
|||
does not work.... I have the same Versions...
|
#157
|
|||
|
|||
With this versions it is possible to login via vB in Wiki AND vB, but as written above you cannot logout both or login through Wiki.
NoeJeko will try to solve the problem. We need some patience... Bruno |
#158
|
|||
|
|||
I am working the issue. Right now I can only claim compatibility with vB 3.6.9-3.7.3 and MW <= 1.12.
|
#159
|
|||
|
|||
1001 Thanks! ... hope you dont lose to much time with this...
|
#160
|
|||
|
|||
Check the MediaWiki 1.13.2 RELEASE-NOTES file.
* AutoAuthenticate hook renamed to UserLoadFromSession I had to change that hook in includes/AuthPlugin_vBBSSO.php below: //$wgHooks['AutoAuthenticate'][] = 'vBSSOAutoAuth'; $wgHooks['UserLoadFromSession'][] = 'vBSSOAutoAuth'; Otherwise Single-Signon did not work with MediaWiki 1.13.2. FYI for y'all. Rick |
#161
|
|||
|
|||
Thanks for your feedback. This is written above, but you still will not be able to
1. logout from wiki -> go back and see if inside wiki really logged out 2. login through Wiki -> check at vB and wiki Or does it work on your side? Bruno |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|