[PHP Help] Password Check
#1

Hi guys,

I'm making an UCP and i have problems with login.My password are wrritten in next way(On SA-MP Server)

Код:
PlayerInfo[playerid][pPass] = udb_hash(inputtext);
Код:
stock udb_hash(buf[]) //HASH PASS
{
    new length=strlen(buf);
    new s1 = 1;
    new s2 = 0;
    new n;
    for (n=0; n<length; n++)
    {
       s1 = (s1 + buf[n]) % 65521;
       s2 = (s2 + s1)     % 65521;
    }
    return (s2 << 16) + s1;
}
Код:
if(udb_hash(inputtext) == PlayerInfo[playerid][pPass]) //password check
I need help,how to make check for udb_hash on website(PHP).I'm beggginer for it
How to check is password good

Код:
$acc = $Db->getRow("SELECT * FROM accounts WHERE p_email = '".$email."' AND p_password = '".$pass."' ");
But it don't will work.I need check with udb_hash ...
Reply


Messages In This Thread
[PHP Help] Password Check - by BalkanEliteRP - 10.02.2018, 08:49
Re: [PHP Help] Password Check - by Mellnik - 10.02.2018, 09:26
Re: [PHP Help] Password Check - by BalkanEliteRP - 10.02.2018, 09:32

Forum Jump:


Users browsing this thread: 1 Guest(s)