From: hickert Date: Mon, 7 Jan 2008 11:58:12 +0000 (+0000) Subject: Removed old session_start and session_destroy calls X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=c83030828a4b33bf18cd2e960b9a657aff0f9b44;p=gosa.git Removed old session_start and session_destroy calls git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8234 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/html/combine.php b/gosa-core/html/combine.php index 69c8a9306..f354f9c73 100644 --- a/gosa-core/html/combine.php +++ b/gosa-core/html/combine.php @@ -22,7 +22,7 @@ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (0); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getFAIscript.php b/gosa-core/html/getFAIscript.php index 1a55d0487..b7bebe34a 100644 --- a/gosa-core/html/getFAIscript.php +++ b/gosa-core/html/getFAIscript.php @@ -66,7 +66,7 @@ function getFAIScript ($id) @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (E_ALL | E_STRICT); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/get_attachment.php b/gosa-core/html/get_attachment.php index 850950ab4..f62ab9fd0 100644 --- a/gosa-core/html/get_attachment.php +++ b/gosa-core/html/get_attachment.php @@ -22,7 +22,7 @@ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); @require_once ("class_glpi.inc"); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getbin.php b/gosa-core/html/getbin.php index 183924935..d2c2b75ec 100644 --- a/gosa-core/html/getbin.php +++ b/gosa-core/html/getbin.php @@ -22,7 +22,7 @@ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (0); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getfax.php b/gosa-core/html/getfax.php index 98e89c7c7..ff114f87e 100644 --- a/gosa-core/html/getfax.php +++ b/gosa-core/html/getfax.php @@ -22,7 +22,7 @@ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (0); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getkiosk.php b/gosa-core/html/getkiosk.php index e5a7b6bc7..183932d3b 100644 --- a/gosa-core/html/getkiosk.php +++ b/gosa-core/html/getkiosk.php @@ -50,7 +50,7 @@ function getkiosk ($id) @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (E_ALL | E_STRICT); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getldif.php b/gosa-core/html/getldif.php index d5e528609..ca95ba561 100644 --- a/gosa-core/html/getldif.php +++ b/gosa-core/html/getldif.php @@ -61,7 +61,7 @@ function dump_ldap ($mode= 0) @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (E_ALL | E_STRICT); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getvcard.php b/gosa-core/html/getvcard.php index 9aba00617..7c0d01477 100644 --- a/gosa-core/html/getvcard.php +++ b/gosa-core/html/getvcard.php @@ -22,7 +22,7 @@ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); error_reporting (0); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/getxls.php b/gosa-core/html/getxls.php index 5db29b8b1..c0d1c0900 100644 --- a/gosa-core/html/getxls.php +++ b/gosa-core/html/getxls.php @@ -466,7 +466,7 @@ function dump_ldap ($mode= 0) /* Basic setup, remove eventually registered sessions */ @require_once ("../include/php_setup.inc"); @require_once ("functions.inc"); -session_start (); +session::start(); /* Logged in? Simple security check */ if (!session::is_set('ui')){ diff --git a/gosa-core/html/helpviewer.php b/gosa-core/html/helpviewer.php index 6fae266d4..fed1414fe 100644 --- a/gosa-core/html/helpviewer.php +++ b/gosa-core/html/helpviewer.php @@ -27,7 +27,7 @@ error_reporting(E_ALL | E_STRICT); restore_error_handler(); header("Content-type: text/html; charset=UTF-8"); -session_start(); +session::start(); /* If no config object is found in the session, abort help */ if (!session::is_set('config')){ diff --git a/gosa-core/html/index.php b/gosa-core/html/index.php index b5e9bf62b..4cd21afb7 100644 --- a/gosa-core/html/index.php +++ b/gosa-core/html/index.php @@ -92,7 +92,7 @@ function displayLogin() /* Set error handler to own one, initialize time calculation and start session. */ -session_start (); +session::start(); /* Destroy old session if exists. Else you will get your old session back, if you not logged out correctly. */ diff --git a/gosa-core/html/logout.php b/gosa-core/html/logout.php index e41c71326..1268cbfc0 100644 --- a/gosa-core/html/logout.php +++ b/gosa-core/html/logout.php @@ -25,7 +25,7 @@ header("Content-type: text/html; charset=UTF-8"); /* try to start session, so we can remove userlocks, if the old session is still available */ -@session_start(); +@session::start(); if(session::is_set('ui')){ /* Get config & ui informations */ @@ -73,8 +73,7 @@ if (isset ($config->data['MAIN']['COMPILE'])){ if (isset($_GET['request'])){ /* destroy old session */ - @session_unset (); - @session_destroy (); + session::destroy (); /* If we're not using htaccess authentication, just redirect... */ if (isset($config->data['MAIN']['HTACCESS_AUTH']) && preg_match('/^(true|yes)$/i', $config->data['MAIN']['HTACCESS_AUTH'])){ diff --git a/gosa-core/html/main.php b/gosa-core/html/main.php index f2759620e..e459b6599 100644 --- a/gosa-core/html/main.php +++ b/gosa-core/html/main.php @@ -84,7 +84,7 @@ if(session::get('_LAST_PAGE_REQUEST') == ""){ * kill session */ if($request_time > $max_life){ - session_unset(); + session::destroy(); new log("security","login","",array(),"main.php called without session - logging out") ; header ("Location: logout.php"); exit; @@ -160,7 +160,7 @@ $plist= session::get('plist'); if (isset($global_check) && $config->data['MAIN']['FORCEGLOBALS'] == 'true'){ echo _("FATAL: Register globals is on. GOsa will refuse to login unless this is fixed by an administrator."); new log("security","login","",array(),"Register globals is on. For security reasons, this should be turned off.") ; - session_destroy (); + session::destroy (); exit (); } diff --git a/gosa-core/html/password.php b/gosa-core/html/password.php index 801bba2cd..d830a8374 100644 --- a/gosa-core/html/password.php +++ b/gosa-core/html/password.php @@ -36,7 +36,7 @@ if(!class_exists("log")){ header("Content-type: text/html; charset=UTF-8"); -session_start(); +session::start(); /* Destroy old session if exists. Else you will get your old session back, if you not logged out correctly. */ diff --git a/gosa-core/setup/class_setup.inc b/gosa-core/setup/class_setup.inc index e16bc546a..c3c0e53e6 100644 --- a/gosa-core/setup/class_setup.inc +++ b/gosa-core/setup/class_setup.inc @@ -49,7 +49,7 @@ class setup /* Ensure that setup is not reachable if gosa.conf (CONFIG_FILE) */ if(file_exists(CONFIG_DIR."/".CONFIG_FILE)){ - session_destroy(); + session::destroy(); header("Location: index.php") ; exit(); } diff --git a/gosa-core/setup/class_setupStep_Finish.inc b/gosa-core/setup/class_setupStep_Finish.inc index 3898c55c5..8a0afd56d 100644 --- a/gosa-core/setup/class_setupStep_Finish.inc +++ b/gosa-core/setup/class_setupStep_Finish.inc @@ -65,7 +65,7 @@ class Step_Finish extends setup_step * - Permisssion are set correctly */ if(isset($_POST['next']) && $exists && !$this->is_world_readable(CONFIG_DIR."/".CONFIG_FILE)){ - session_destroy(); + session::destroy(); header("Location: index.php"); exit(); }