Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Add-ons

Reply
 
Thread Tools
ipbAuth - Use old Invision Power Board Passwords after migrating to vBulletin Details »»
ipbAuth - Use old Invision Power Board Passwords after migrating to vBulletin
Version: 1.00, by viarun viarun is offline
Developer Last Online: Oct 2018 Show Printable Version Email this Page

Category: Integration with vBulletin - Version: 4.0.1 Rating:
Released: 02-15-2010 Last Update: Never Installs: 18
Uses Plugins
Re-useable Code Additional Files  
No support by the author.

For anyone that's migrating from IPB ( Invision Power Board ) 2.X to vBulletin 4.x. The reason I built this is because the impex import system does not migrate passwords for a move from IPB to vBulletin. This is largely because the passwords are hashed differently, so there's no way to "convert" a password.

This plugin takes a different approach, where you keep the old IPB passwords around, and authenticate users against it first. If they authenticate successfully, then we sync the password the user typed in with vBulletin. Voila...a migration without making your users reset their passwords.

Borrowed heavily from ideas by malcolmx in his LDAP Auth Plugin. THANKS MALCOLMX!

Installation Notes:

1. copy ipbAuth directory to your vb forum installation directory
2. change the path to controller.php directory in ipb-plugin.xml
3. copy the hooks_ipb.xml to FORUM_ROOT/includes/xml directory
4. in login.php search for:
Code:
if ($vbulletin->GPC['vb_login_username'] == '')
         {
          eval(standard_error(fetch_error('badlogin', $vbulletin->options['bburl'], ....
         }
And add this hook statement like so:
Code:
(if ($vbulletin->GPC['vb_login_username'] == '') 
{ 
  eval(standard_error(fetch_error('badlogin', $vbulletin->options['bburl'], .... 
} 
($hook = vBulletinHook::fetch_hook('ipb_login_hook')) ? eval($hook) : false;
5. activate plugin system (if not done already) in admincp
6. in admin cp import the product at "Plugins & Products -> Download / Upload Plugins", use "Import Plugin Definitions XML File" at the bottom of the page, example import input './ipbAuth/ipb-plugin.xml'
7. in includes/class_bootstrap.php search for:

Code:
$show['nopasswordempty']
then change:

Code:
defined('DISABLE_PASSWORD_CLEARING') ? 1 : 0;
to:

Code:
defined('DISABLE_PASSWORD_CLEARING') ? 0 : 1;
( note that this causes the browser to skip hashing the password in javascript, and passwords will be sent cleartext to the server. technically, a security risk, although many, many, bulletin board systems do this by default. This is the only sensible way to get the cleartext password to be synced though. no other clean way to sync IPB to vB. You can, of course, turn this whole plugin off after most of your users have migrated, and then remove this change. The passwords are properly hashed in the database, and not written to disk, so the risk is relatively low.)


8. Configure the database settings in ipbconfig.inc.php ... this should point to your IPB database that has the members_converge table in it. Be sure to supply a username and password that can read and update the table. Make a copy of the database first...before you turn this plugin on!

9. Make a backup copy of the old IPB database first...before you turn this plugin on!

10. Test

A little story: The whole reason this happened was that IPB treated me like crap. I was a long-time customer of their hosted board service on their 2.X product. Last weekend, I had planned to upgrade to 3.x, and move my board to my own servers. So, I logged into their site and purchased the 3.x product.

It popped up an error that basically said they had flagged the purchase, and were going to keep my money, but not let me download the software until I could be "verified"...perhaps up to 2 days later. So, I decided I didn't like being treated like a thief. I bought a brand-new copy of vB, and wrote this plugin to ease the migration for my board members. I'm posting it here so that hopefully, more people can move away from IPB. Karma rocks.


Download

Download Now

File Type: zip ipbAuth.zip (4.9 KB, 112 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 07-11-2010, 04:11 PM
ozzy47's Avatar
ozzy47 ozzy47 is offline
 
Join Date: Jul 2009
Location: USA
Posts: 10,929
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is their a way to have my ipb v2.3.6 board read the members and passwords from vb 4.0

I have ipb for my arcade and need my vb forum members to be able to use their vb log on info at my ipb board
Reply With Quote
  #23  
Old 08-06-2010, 03:26 PM
bigrover bigrover is offline
 
Join Date: Jun 2010
Posts: 74
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This mod solved a big problem and saved me a lot of work. Thank you for putting in the time to code this solution. I also appreciate the level of commenting in your code. It made it very easy for me to see what was happening, know what to expect in the old IPB database to confirm it worked, and allowed me to make a change to search on a different field when looking up the userid. Good work.
Reply With Quote
  #24  
Old 02-21-2011, 08:12 PM
deven316 deven316 is offline
 
Join Date: Jan 2005
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

HELP!!

I tried to install this mod as i have upgraded from IPB 2.3.6, i thought i followed the directions correctly, but when i try and login with any username i get this error

Parse error: syntax error, unexpected $end in /home/goozebum/public_html/forums/ipbAuth/controller.php on line 85
Reply With Quote
  #25  
Old 02-21-2011, 08:35 PM
briggsbw briggsbw is offline
 
Join Date: Mar 2008
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm guessing this will work for IPB 2.3 to vB 3.8 as well with some table name changes?
Reply With Quote
  #26  
Old 02-25-2011, 07:02 AM
cpvrx cpvrx is offline
 
Join Date: Jul 2009
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great plugin!
Reply With Quote
  #27  
Old 03-10-2011, 01:15 PM
Rebecca217 Rebecca217 is offline
 
Join Date: May 2002
Posts: 84
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by briggsbw View Post
I'm guessing this will work for IPB 2.3 to vB 3.8 as well with some table name changes?
I'm curious about this, too.

Btw, excellent idea, and thanks so much for posting this mod!
Reply With Quote
  #28  
Old 01-12-2013, 05:51 PM
ripley ripley is offline
 
Join Date: Nov 2010
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Receiving the following:

Fatal error:

A required field called import_ipbpass is missing or has an invalid value.

Unable to proceed with save while $errors array is not empty in class vB_DataManager_User in [path]/includes/class_dm.php on line 849
Reply With Quote
  #29  
Old 05-02-2013, 06:18 AM
onespot onespot is offline
 
Join Date: May 2008
Posts: 21
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey Everyone - I spent a hell of a lot of time trying to get some functionality that I was just able to finally get wanted to share with everyone.

Basically my clients IPB didn't rely on usernames - it was mostly email addresses so I wanted this process to ALSO check if the user typed in an EMAIL address into the login and initiate this script properly if email matched the "email" field in IPB.

I then use https://vborg.vbsupport.ru/showthread.php?t=275348 which will take over the login process AFTER the new PW is saved.

All you need to do is edit the controller.php file in your ipbauth folder:

Find
PHP Code:
function fetch_userid_from_username($username) {
        global 
$vbulletin;
        if (
$user 
            
$vbulletin->db->query_first("SELECT userid 
                 FROM " 
TABLE_PREFIX "user WHERE username = '" 
                 
$vbulletin->db->escape_string(trim($username)) . "'")) {
                return 
$user['userid'];
        } 
Add Below:
PHP Code:
else if ($user 
            
$vbulletin->db->query_first("SELECT userid 
                 FROM " 
TABLE_PREFIX "user WHERE email = '" 
                 
$vbulletin->db->escape_string(trim($username)) . "'")) {
                return 
$user['userid'];
        } 
Works like a charm!

I'm no programmer so use this at your own risk - I very well could be missing something and it could not be doing something that is important here...
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:24 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.08095 seconds
  • Memory Usage 2,317KB
  • Queries Executed 24 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (5)bbcode_code
  • (2)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (8)postbit
  • (1)postbit_attachment
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete