Location: PHPKode > scripts > Secure Session Management > secure-session-management/config.common.php
<?php
	ob_start();
	define('SECURITY_SALT', 'proud_for_india');		
	define('LEVEL_SESS_NORMAL',0);
	define('LEVEL_SESS_HIGH',1);
	$sessions   =  array( 
							 'sess_01' => array( 
												'name' =>'3GROCKETSESS',
												'use'	=>'file',
												'life_time'	=>0,
												'level'  =>LEVEL_SESS_HIGH,
												'ciphered' =>function_exists('mcrypt_module_open') ,
												'regenerate' => true,
												'ideal'	=>60, // IN SEC
												'postCheck' => true ,  // Session expired if requested method is not post
												'userAgentCheck' =>true , // Session expired if requested user agent has changed during sesion 
												'refreshCheck'=>true,// Session expired if requested page is refrshed
												'session_path' => 'temp_sess'
												)

						);
	require('systems' . DIRECTORY_SEPARATOR . 'mcrypt_cryptography.php');
	require('systems' . DIRECTORY_SEPARATOR . 'session_manager.php');
	
	SessionManager::setSessions($sessions);
	$sess  =SessionManager::autoStartSession('sess_01');
		
	if( ! $sess->checkSet('AUTH_DATA') && basename($_SERVER['SCRIPT_FILENAME']) !='login.php'  ) {
		header("location: login.php");
		exit ;
	}
	
	if(  $sess->checkSet('AUTH_DATA') &&  ! $sess->checkSession() ) {
		$sess->destroy();
		header("location: sess_expired.html");
		exit ;
	}
	
	
	function pr($data,$pre = true , $flag= 0 ) { 
		if( $pre)
			echo "<pre>";
		if( is_array($data) || is_object($data)  || is_resource($data)  )
			print_r($data);
		elseif( is_string($data) )
			echo $flag ?  htmlentities( $data) :$data   ;
		else
			print($data);		
		if( $pre )	
			echo "</pre>";
	}
?>
Return current item: Secure Session Management