[Behaviour] Keep post data on Login
[Critical?] ImageMagick exploit »

CerealGuy

  • Posts: 317
[Behaviour] Keep post data on Login
«  »
Following problem occurs from time to time:
When I'm, trying to create a new post and during this the session expires, the content gets lost. I think that's true to all $_POST related stuff. $_GET stuff is fine because of the redirection after the login.

Idea: Put all $_POST data in a hidden form when the Login form is getting displayed and try to send that back to the original form/action. I will try to do that.
How is SMF doing this?

Nao

  • Dadman with a boy
  • Posts: 15,927
[Behaviour] Re: Keep post data on Login
« Reply #1,  »
I don't think SMF is doing anything about that..?

Your session shouldn't usually expire anyway..? I think the default in Wedge is the upper end of our cookie length choices..?

CerealGuy

  • Posts: 317
[Behaviour] Re: Keep post data on Login
« Reply #2,  »
This works until your session expires. The bigger the length the smaller the chance of losing your stuff. Still this is something that bugs me, and should be done better (in my opinion).

emanuele

  • Posts: 125
[Behaviour] Re: Keep post data on Login
« Reply #3,  »
If you plan on putting $_POST/$_GET data in hidden inputs, remember that if done slightly wrong is a potential security risk, very similar to the one fixed two or three years ago for the admin login function.

CerealGuy

  • Posts: 317
[Behaviour] Re: Keep post data on Login
« Reply #4,  »Last edited
Quote from emanuele on August 11th, 2016, 11:02 PM
If you plan on putting $_POST/$_GET data in hidden inputs, remember that if done slightly wrong is a potential security risk, very similar to the one fixed two or three years ago for the admin login function.
That's the thing.  It's a potential CSRF vulnerabiltiy if done wrong (?!). Or at least, it's what I muse about.