From 63eda2109992301e9e033f66c5d6f4912b1d56f5 Mon Sep 17 00:00:00 2001 From: Christophe Nowicki Date: Mon, 20 Sep 2004 16:01:08 +0000 Subject: PHP session are now stored in the database A now table was added 'sso_session' for storing information about the PHP Session, it's possible to view logged user Logout destroy the PHP session in the IdP Bug : user can't sso twice ;( --- php/Attic/examples/sample-sp/setup.php | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) (limited to 'php/Attic/examples/sample-sp/setup.php') diff --git a/php/Attic/examples/sample-sp/setup.php b/php/Attic/examples/sample-sp/setup.php index c6c44228..2886c88a 100644 --- a/php/Attic/examples/sample-sp/setup.php +++ b/php/Attic/examples/sample-sp/setup.php @@ -167,8 +167,22 @@ $query = "CREATE TABLE sessions ( id varchar(32) primary key, - expiry integer, - data text + lastupdate timestamp, + data text)"; + + $res =& $db->query($query); + if (DB::isError($res)) + die($res->getMessage()); + + print "OK"; + + print "
Create table 'sso_sessions' : "; + $query = "DROP TABLE sso_sessions CASCADE"; + $res =& $db->query($query); + + $query = "CREATE TABLE sso_sessions ( + name_identifier character varying(100), + session_id character varying(32) )"; $res =& $db->query($query); @@ -177,6 +191,7 @@ print "OK"; + $db->disconnect(); $keys = array_keys($config); @@ -375,6 +390,9 @@ +

Index +

+

Copyright © 2004 Entr'ouvert