Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Tests for SessionManager preserveStorage flag #7129

Conversation

Martin-P
Copy link
Contributor

Zend/Session/SessionManager::start() has an optional flag $preserveStorage: Zend/Session/SessionManager line 84

If set to true, current session storage will not be overwritten by the contents of $_SESSION.

This PR tests that functionality. Not all tests pass, because the $preserveStorage flag is not working as it should.

@Ocramius Ocramius added this to the 2.3.5 milestone Feb 1, 2015
@Ocramius Ocramius self-assigned this Feb 1, 2015
@Ocramius
Copy link
Member

Ocramius commented Feb 1, 2015

@Martin-P that functionality actually never worked in 2.x as far as I can see...

@Martin-P
Copy link
Contributor Author

Martin-P commented Feb 1, 2015

That's possible, I only added the tests for what it should do. Not sure if it needs fixing if nobody uses this feature.

@weierophinney weierophinney modified the milestones: 2.3.5, 2.3.6, 2.4.0 Feb 18, 2015
@weierophinney
Copy link
Member

@Martin-P want to take a crack at making it work? If so, I need changes by tomorrow, 19 March 2015.

@Martin-P
Copy link
Contributor Author

@weierophinney I do not think this can ever work. The security fix for session validators made me aware of this feature (ddbf43a). The preservation of $_SESSION data is part of the security fix. Making the preservation of $_SESSION data optional would compromise the security fix.

To make this work the security fix needs a change. The tests covering the security fix are present, so theoretically it should not be a problem. I don't know if you consider it an option to change the security fix?

@weierophinney
Copy link
Member

@Martin-P We can change the security fix so long as the tests introduced by it continue to pass.

@Martin-P
Copy link
Contributor Author

I can take a look at this, but I think it will be after the 2.4.0 release however.

@weierophinney weierophinney removed this from the 2.4.0 milestone Mar 19, 2015
@GeeH
Copy link

GeeH commented Jun 28, 2016

This issue has been moved from the zendframework repository as part of the bug migration program as outlined here - http://framework.zend.com/blog/2016-04-11-issue-closures.html
New issue can be found at: zendframework/zend-session#50

@GeeH GeeH closed this Jun 28, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants