Unable to login, changing wp-config.php workaround

I am encountering this issue too. The cause is the security keys are being generated incorrectly. They are being defined at the very end of the wp-config.php file, which is too late in the process and it breaks things. They should be declared in the spot where the PHP comments say that the security keys should be.