summaryrefslogtreecommitdiff
path: root/UPGRADING.INTERNALS
diff options
context:
space:
mode:
authorYasuo Ohgaki <yohgaki@php.net>2015-02-04 11:54:16 +0900
committerYasuo Ohgaki <yohgaki@php.net>2015-02-04 11:54:16 +0900
commit62304930051c566abb8ba4de16433c617b631d7a (patch)
tree3ef32fb38cd2e8cd60224b174cecca0b15ff2256 /UPGRADING.INTERNALS
parentdbb1298fdba7099a025f9167b8fa482aef7742bb (diff)
downloadphp-git-62304930051c566abb8ba4de16433c617b631d7a.tar.gz
Update UPGRADING.INTERNALS Session section
Diffstat (limited to 'UPGRADING.INTERNALS')
-rw-r--r--UPGRADING.INTERNALS20
1 files changed, 14 insertions, 6 deletions
diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS
index ddce1b8c5d..6b22879862 100644
--- a/UPGRADING.INTERNALS
+++ b/UPGRADING.INTERNALS
@@ -214,12 +214,20 @@ PHP 7.0 INTERNALS UPGRADE NOTES
- PS_MOD_UPDATE_TIMESTAMP() session save handler definition is added. New
save handler should use PS_MOD_UPDATE_TIMESTAMP() definition. Save handler
- must not refer/change PS() variables directly from save handler.
- - PS_MOD_UPDATE_TIMESTAMP() defines validate_sid() handler. This handler
- must validate if requested session ID is in session data storage or not.
- Internal save handler needed to asscess PS(id) directly to validate it.
- Do not access PS(id), but use this handler.
- - PS_MOD_UPDATE_TIMESTAMP() defines update_timestamp() handlers. This handler
+ must not refer/change PS() variables directly from save handler. Use
+ parameters.
+ - PS_MOD()/PS_MOD_SID() macro exist only for transition. Beware these
+ save handlers are less secure and slower than PS_MOD_UPDATE_TIMESTAMP().
+ - PS(invalid_session_id) was removed. It was never worked as it supposed.
+ To report invalid session ID, use PS_VALIDATE_SID() handler.
+ - PS_VALIDATE_SID() defines session ID validation handler. This handler
+ must validate if requested session ID exists in session data storage or not.
+ Do not access PS(id) directly, but use this handler and it's parameter.
+ - PS_UPDATE_TIMESTAMP() defines timestamp updating handler. This handler
must update session data timestamp for GC if it is needed. e.g. Memcache
updates timestap on read, so it does not need to update timestamp. Return
SUCCESS simply for this case.
+ - PS_CREATE_SID() should check session ID collision. Return NULL for failure.
+ - More documentation can be found in ext/session/mod_files.c as comments.
+ mod_files.c may be used as reference implementation.
+