FrenchTroll Posted July 2, 2007 Share Posted July 2, 2007 Hello, Sorry for my english but i am french... How can we write in a inifile an encrypted password by an imputbox ? #include <guiconstants.au3> #include <string.au3> GUICreate("test") $input = GUICtrlCreateInput ( "", 10, 5, 100, 20, $ES_PASSWORD) $EncryptButton = GuiCtrlCreateButton('Encrypt', 31, 54, 40, 40) GUISetState () While 1 sleep(1) $msg = GUIGetMsg() Select Case $msg = $EncryptButton $pass = GuiCtrlRead($input) IniWrite("Conf.ini", "PASS", "Mot de passe", _StringEncrypt(0,$pass,"12345","2")) ExitLoop EndSelect Wend that return only one strange letter... THANKS Link to comment Share on other sites More sharing options...
Valuater Posted July 2, 2007 Share Posted July 2, 2007 0 is to decrypt #include <guiconstants.au3> #include <string.au3> GUICreate("test") $input = GUICtrlCreateInput ( "", 10, 5, 100, 20, $ES_PASSWORD) $EncryptButton = GuiCtrlCreateButton('Encrypt', 31, 54, 40, 40) GUISetState () While 1 sleep(1) $msg = GUIGetMsg() Select Case $msg = $EncryptButton $pass = GuiCtrlRead($input) ;IniWrite("Conf.ini", "PASS", "Mot de passe", _StringEncrypt(1,$pass,"12345","2")) $encypt = _StringEncrypt(1,$pass,"12345","2") MsgBox(0x0,"encypted", $encypt) $dencypt = _StringEncrypt(0,$encypt,"12345","2") MsgBox(0x0,"encypted", $dencypt) ExitLoop EndSelect Wend 8) Link to comment Share on other sites More sharing options...
Developers Jos Posted July 2, 2007 Developers Share Posted July 2, 2007 change this line: IniWrite("Conf.ini", "PASS", "Mot de passe", _StringEncrypt(1, $pass, "12345", 2)) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
FrenchTroll Posted July 2, 2007 Author Share Posted July 2, 2007 (edited) Arff... Thanks both Edited July 2, 2007 by FrenchTroll Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now