News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Login Error with Core Theme Only

Started by jonesH, March 21, 2019, 05:46:41 PM

Previous topic - Next topic

jonesH

Hi. I have SMF with Simple Portal and SMF Gallery Lite (all stock, new install, Admin the only user).
If running the Core theme in a fresh Firefox browser,  logging in from the top-left corner boxes leads to this: "Your session timed out while posting.  Please go back and try again." Also, the url string looks something like this: ""http://localhost/forums/testforum/index.php?PHPSESSID=utvtimf4k58q1j6mh7nh1id96r&action=login2".
Subsequent attempts of the same change to this look instead: "http://localhost/forums/testforum/index.php?action=login2".
I tried this with Firefox set up in various ways, because I get the feeling this error has something to do with the cookie handling. But I might be wrong.

At setup time, I chose the "Database sessions" option.

This error only happens to me in the CoreTheme and only from the top-left boxes. All other options log me in just fine.

What might be the problem?...
Thanks for looking into this.

Arantor

The core theme has a bug and wasn't patched properly in previous versions.

https://wiki.simplemachines.org/smf/Login_error_2.0.14 has more information.
Holder of controversial views, all of which my own.

Sir Osis of Liver

You have to add session check to header login in Core theme.

index.template.php

Find this -



<input type="hidden" name="hash_passwrd" value="" />



Do this -



<input type="hidden" name="hash_passwrd" value="" />
<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" />


Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

jonesH

Thank you both for your quick replies!
I tried Aranthor's advice and login works fine now. I will undo that and then try Sir Osis if Liver's method - I am sure it will work as well. Then I will try to make sense of the code.
Again, thanks!

Arantor

Considering that they're literally the same advice presented in different ways... ;)
Holder of controversial views, all of which my own.

Sir Osis of Liver

It's the same fix.  The session check was added to login in 2.0.14 for added security.  It's included in both header login and login window in Curve theme, but was omitted from Core header login.  Some custom themes have it, some don't and have to be fixed.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

jonesH

Yes, indeed, I see now that each advice tells the same steps and leads to the same result...

arielvered

Quote from: Arantor on March 21, 2019, 05:50:04 PM
The core theme has a bug and wasn't patched properly in previous versions.

https://wiki.simplemachines.org/smf/Login_error_2.0.14 has more information.

I have tried adding this and it did not help.
I am getting this error only on a single computer, on a different computer (same user) not getting it.
I have cleared cache and passwords, etc. Even tried a different browser.

Advertisement: