SA-MP Forums Archive
Y_Ini changepass problem - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Y_Ini changepass problem (/showthread.php?tid=449281)



Y_Ini changepass problem - SantoN - 08.07.2013

Hello,
I created a command which allows a user to change his account password. The problem is that, when he entered the password in the dialog, and hit 'Change', the password doesn't change, is still the same.
Here's the change password dialog

pawn Код:
case DIALOG_PASSWORDCHANGE:
        {
            if(!response) return SendClientMessage(playerid, COLOR_RED, "* You cancelled this operation");
            if(response)
            {
                if(!strlen(inputtext)) return ShowPlayerDialog(playerid,DIALOG_PASSWORDCHANGE, DIALOG_STYLE_PASSWORD,"Password manager","Please type your new password:","Done","Cancel");
                new INI:File = INI_Open(UserPath(playerid));
                INI_SetTag(File,"data");
                INI_WriteInt(File,"Password",udb_hash(inputtext));
                INI_Close(File);
                ShowPlayerDialog(playerid, DIALOG_SUCCESS_1, DIALOG_STYLE_MSGBOX,""COL_WHITE"Success!",""COL_GREEN"Password changed!","Close","");
            }
        }



Re: Y_Ini changepass problem - SantoN - 08.07.2013

bump


Re: Y_Ini changepass problem - SantoN - 08.07.2013

Quote:
Originally Posted by ******
Посмотреть сообщение
DO NOT try write your own password management system, they are too important to get wrong, as you have (udb_hash). Download an existing good user system, of which there are frankly very few.
Uhm.. and where can I find a good one? (I mean, can you link me the best one that u know?)
Btw, I know that the passwords are very important, so, I'm hosted on a my own Linux VPS, and as a expert Linux user I can guarantee you the system is fully secured, you won't find a way to get into the user accounts in every way you will try..


Re: Y_Ini changepass problem - EiresJason - 08.07.2013

Here is a tutorial on creating a good secure registration system using Y_INI and Whirlpool (secure hashing).
https://sampforum.blast.hk/showthread.php?tid=270229