HotKeyIt/ahkdll

how do i change default password?

biax opened this issue · 1 comments

biax commented

I've read your instructions:

    default password AutoHotkey is now better hidden and it is easier to set own password
    Make sure to amend or add g_default_pwd.. entries, also in globaldata.h and update the length of it here and here.
    The password itself needs to be changed here, use you own fake entries. You can also have empty (\0) characters in between or use for example separate function to generate the password...
    The best method is to generate the password dynamically through separate function(s) so it is not saved directly in source and that part of source code is not open to public!```

Are you able to guide/example on how to make decryption most difficult, and changing the default password to "biax" and how to dynamically set a password? I've read your instructions and still aint sure how to.

Using the same method as autohotkey password you would need to change:
https://github.com/HotKeyIt/ahkdll/blob/master/source/util.cpp#L3219
https://github.com/HotKeyIt/ahkdll/blob/master/source/script.cpp#L3701
https://github.com/HotKeyIt/ahkdll/blob/master/source/script.cpp#L3750

dynamic password is a bit more difficult and you should give it a try. e.g. instead of
pw[i] = pwd == g_default_pwd ? (TCHAR) _T("A\0\0\0\0u\0\0\0\0t\0\0\0\0o\0\0\0\0H\0\0\0\0o\0\0\0\0t\0\0\0\0k\0\0\0\0e\0\0\0\0y\0\0\0\0")[i*5] : (TCHAR)*pwd[i];
you would call a function that generates the password based on anything you can come up with, you can use debug to check the generated password:
pw[i] = pwd == g_default_pwd ? mypasswordfunc(i) : (TCHAR)*pwd[i];