Can't make first time login
Hashtopolis 0.6.0 Windows 7 x64 Bitnami WAMP Stack 7.1.20
Just want try hashtopolis on my Windows machine. Can't make fist time login to hashtopolis just after successfully installation. Admin user was created on last step of installation, corresponding row with loginname, email and password hash appeared in db.users, but I can't login with these credentials, server tell me "Wrong username/password/OTP!" What am i doing wrong? except of using Windows of course)
Are you sure that you try with the same password like the one you created on the installation step?
To make sure that there is not a problem with some requirements, please check the apache2 error log if there is any warning/error during login.
If you want to reset the password to try again, there is a script at src/install/updates/reset.php which can be used to reset a users password without using email. Just edit the script and fill in the appropriate values (new password and userId) and then call it with php -f src/install/updates/reset.php password.
Of course, i tried couple of times with recreated databases, and result was the same. Script helped me, thank you. I tried to figure out myself where is the problem, but unsuccessfully.. Is it depends on OS or maybe MySQL version?
Hmm strange. Have you checked the apache error log? Because the only reason I could imagine is that there is a dependency missing and then there should be an error in the log.
There is no errors during installation and first trying to log in error.log
Can you check in your php.ini of WAMP if the openssl extension is loaded. Because the only thing I can imagine to get problems with the login from the dependencies is openssl. The MySQL version definitely should not affect the login, unless you have configured some strange collation.
I just checked with XAMPP on Windows 10 and the 0.6.0 release and there was no problem with login after installation.
I think I found the solution for your problem. Basically, WAMP is not a good solution for running Hashtopolis, it does some aggressive caching of PHP files. This causes that in case of the installation this is the reason that it takes some time until it doesn't forward you to the installation anymore (after the completion). Also it causes, that when your account is created, it still uses the pepper placeholders to hash instead of the ones generated during the installation and therefore your login does not work anymore.
There are two solutions:
- Don't use WAMP
- Disable the caching feature in the php.ini:
opcache.enable=0
I am having similar login problems. Sys is ubuntu 16.04, nginx, php7 Doesn't matter if opcache is enabled or not. As long as I do the login with the old 0.5.0 codebase I can carry over the session to the new version.
@dropdeadfu in your case there is also nothing in the error log of nginx?
@s3inlc nope, I also tried to debug Login.class.php with no success. Something is going wrong with line 114: else if (!Encryption::passwordVerify($password, $user->getPasswordSalt(), $user->getPasswordHash())) { But I couldn't trace any of your changes to this.
There were not really changes to the login/hashing procedure, so it's really surprising that suddenly these problems appear. Did you check that the pepper values were not overwritten in the Encryption.class.php?
if the pepper would be bad, wouldn't I be unable to login with the old version as well? debugging it, getting closer...
oh yea, you were right, the pepper was fucked..still PEPPER123_
I assume the both issues are solved, therefore I close this issue. Please reopen if this is not the case.