Help login/register
#1

https://sampforum.blast.hk/showthread.php?tid=273088

I'm trying to make this l/r system to save the password with words, not numbers but i have
some troubles..can someone help?..Or make it for me.
Reply
#2

Can you please elaborate more? I didnt understand what is it you want to do.

is it INI_WriteInt you're talking about? well if the field is of integer type, you use that method..
Reply
#3

The thing you are trying to do will not work.
Your passwords are encrypted in order to work.
In the tutorial you mentioned udb_hash is used.
You will have to use this in order to work.
You can not save the whole password and then read it in normal characters(words)
Example if your password is 12345678 or password12, you can not save it as that. It is saved in an encrypted way. which gets called on login also:
if(udb_hash(inputtext) == PlayerInfo[playerid][pPass])

What you are trying to do will not work and why would you even want that?
I wouldn't want to join a server where the owner just can see my password by opening a file.
Because when the owner can, someone else maybe be able to do also.
Reply
#4

Quote:
Originally Posted by jasperschellekens
Посмотреть сообщение
The thing you are trying to do will not work.
Your passwords are encrypted in order to work.
In the tutorial you mentioned udb_hash is used.
You will have to use this in order to work.
You can not save the whole password and then read it in normal characters(words)
Example if your password is 12345678 or password12, you can not save it as that. It is saved in an encrypted way. which gets called on login also:
if(udb_hash(inputtext) == PlayerInfo[playerid][pPass])

What you are trying to do will not work and why would you even want that?
I wouldn't want to join a server where the owner just can see my password by opening a file.
Because when the owner can, someone else maybe be able to do also.
Cause i'm trying to do other things with it ..thats why.
Reply
#5

Hashed code is generated with random characters. unless you make your own encryption system, whirlpool or any other hashing method will not give desired results.
Reply
#6

Quote:
Originally Posted by adri1
for(new i, j = strlen(the_password_here); i < j; i++)
{
if(the_password_here[i] == 'the_existing_number') the_password_here[i] = 'replace_with_this';
}
you can use this AFTER udb_hash is used, so if you wanna replace all numbers i guess something like this will work if placed AFTER udb_hash was used in a dialogue response, replace inputtext if you're using another login system:
PHP код:
for(new istrlen(inputtext); <= ji++)
{
    if(
inputtext[i] == '1'inputtext[i] = 'a';
    if(
inputtext[i] == '2'inputtext[i] = 'b';
    if(
inputtext[i] == '3'inputtext[i] = 'c';
    if(
inputtext[i] == '4'inputtext[i] = 'd';
    if(
inputtext[i] == '5'inputtext[i] = 'e';
    if(
inputtext[i] == '6'inputtext[i] = 'f';
    if(
inputtext[i] == '7'inputtext[i] = 'g';
    if(
inputtext[i] == '8'inputtext[i] = 'h';
    if(
inputtext[i] == '9'inputtext[i] = 'i';
    if(
inputtext[i] == '0'inputtext[i] = 'j';
    } 
this will result in all passwords having the exact same letters BUT in different order, DON'T forget to do the exact same thing when a player logs in, you have to load the password the exact same way it was saved, goodluck.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)