Problem in log in.

 
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
alfi



Joined: 04 Nov 2008
Posts: 2
Location: Poland

PostPosted: Tue Nov 04, 2008 4:24 pm    Post subject: Problem in log in. Reply with quote
Hi, I'm trying to use your extensions to allow user form fluxBB to login to MediaWiki. Everything looks like working - connection to database, taking user information and so on.. but it seems that something wrong is with password.

I think that the best method to show you what is wrong, will be this picture:


http://fansubs.pl/wiki/
user: test
pass: test

Thanks for any help Smile
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Wed Nov 05, 2008 11:09 am    Post subject: Reply with quote
Is this you?

http://cksum.org/blog/10-authflux-mediawiki-fluxbb-integration
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Wed Nov 05, 2008 11:10 am    Post subject: Reply with quote
Is this your method?

Code:
      /**
       * HACK puntal.fr
       * FluxBB n'utilise pas forcément md5
       */
      public function passwordHash( $str ) {
            if (function_exists('sha1'))    // Only in PHP 4.3.0+
                  return sha1($str);
            else if (function_exists('mhash'))      // Only if Mhash library is loaded
                  return bin2hex(mhash(MHASH_SHA1, $str));
            else
                  return md5($str);
      }
Back to top
View user's profile Send private message
root
Site Admin


Joined: 24 Jun 2005
Posts: 471

PostPosted: Wed Nov 05, 2008 11:24 am    Post subject: Reply with quote
Looks like the sha1 password hash for test is being returned by the passwordHash() method. But the password in the database is not test.

test a94a8fe5ccb19ba61c4c0873d391e987982fbbd3

The hash 749d446ae1792c0560eabe0f5ebdb882da809b82 does not return anything when I do a lookup on it.
Back to top
View user's profile Send private message
alfi



Joined: 04 Nov 2008
Posts: 2
Location: Poland

PostPosted: Wed Nov 05, 2008 4:45 pm    Post subject: Reply with quote
Thank you for your fast reaply.

Hmm.. it seems that FluxBB 1.3 beta 2, which version I'm using, use for password something more called salt.

For test user:
username: test
password: 749d446ae1792c0560eabe0f5ebdb882da809b82
salt: 96P%BR!mX+$-

Directly taken from database. It's seems that this is a problem.

No, it's not my website and it's not me, I just left comment on that place.

And yes, I'm using this code for password hash that you posted.
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
Page 1 of 1

 
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