Skip to content
Snippets Groups Projects
Commit 28552e0b authored by Olav Morken's avatar Olav Morken
Browse files

authmemcookie: Set expiry time of session data when saving to memcache.

Patch by Ernesto Revilla.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1594 44740490-163a-0410-bde0-09ae8108e29a
parent 5bd5945e
No related branches found
No related tags found
No related merge requests found
...@@ -103,7 +103,8 @@ try { ...@@ -103,7 +103,8 @@ try {
$memcache = $amc->getMemcache(); $memcache = $amc->getMemcache();
$memcache->set($sessionID, $data); $expirationTime = $session->remainingTime();
$memcache->set($sessionID, $data, 0, $expirationTime);
/* Register logout handler. */ /* Register logout handler. */
$session->registerLogoutHandler('SimpleSAML_AuthMemCookie', 'logoutHandler'); $session->registerLogoutHandler('SimpleSAML_AuthMemCookie', 'logoutHandler');
...@@ -113,5 +114,3 @@ try { ...@@ -113,5 +114,3 @@ try {
} catch(Exception $e) { } catch(Exception $e) {
SimpleSAML_Utilities::fatalError($session->getTrackID(), 'CONFIG', $e); SimpleSAML_Utilities::fatalError($session->getTrackID(), 'CONFIG', $e);
} }
?>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment