MyBB Community Forums

Full Version: [solved]What encoding password in myBB ?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

First i want to underline the fact that i'm french and i don't speak english very weel, so sorry for my language !

Then, i want to develop my own website using the same database of my forum myBB. I try to use the php function md5() but don't work Sad

so i suppose that myBB use different encoding for the password in the database... what function can i use for encode a data to compare with the password in the database ?

What file i need to include in order to can use the function ? What the php code use in this function ?

Thanks !
Dahevos.
It's md5'd and salted. I don't know how you could replicate it though.
salted = ?

I see on google that salt is a random .... but myBB can found the password when we login... can i use myBB function login ?
(2009-10-23, 08:01 PM)Dahevos Wrote: [ -> ]salted = ?

I see on google that salt is a random .... but myBB can found the password when we login... can i use myBB function login ?
http://en.wikipedia.org/wiki/Salt_%28cryptography%29

The following determines your password:
Quote:md5(md5($salt).$password);
Bear in mind that your $password variable is already md5() encrypted
so to be more accurate, it would be:
Quote:md5(md5($salt).md5(password-as-text));
Where $salt = random_str(8); or if you have an existing user, they would already have $salt written to database.

So, in order to create your own custom login ,you will have to query user table for username,password and salt, then write your login validation.
thanks ! it's works ! thanks you very much !