|
From: MW <jo...@us...> - 2008-02-09 12:52:40
|
Update of /cvsroot/mxbb/core In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv30412 Modified Files: common.php login.php Log Message: part of project wide change of using request_vars wrapper class instead of explicite and unfiltered $HTML_*_VARS Index: login.php =================================================================== RCS file: /cvsroot/mxbb/core/login.php,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** login.php 4 Feb 2008 16:03:02 -0000 1.25 --- login.php 9 Feb 2008 12:52:36 -0000 1.26 *************** *** 38,44 **** // session id check ! if (!empty($HTTP_POST_VARS['sid']) || !empty($HTTP_GET_VARS['sid'])) { ! $sid = (!empty($HTTP_POST_VARS['sid'])) ? $HTTP_POST_VARS['sid'] : $HTTP_GET_VARS['sid']; } else --- 38,44 ---- // session id check ! if (!$mx_request_vars->is_empty_request('sid')) { ! $sid = $mx_request_vars->request('sid', MX_TYPE_NO_TAGS); } else *************** *** 47,51 **** } ! if( isset($HTTP_POST_VARS['login']) || isset($HTTP_GET_VARS['login']) || isset($HTTP_POST_VARS['logout']) || isset($HTTP_GET_VARS['logout']) ) { --- 47,51 ---- } ! if($mx_request_vars->is_request('login') || $mx_request_vars->is_request('logout') ) { *************** *** 71,75 **** // user not already logged in // ! if( !$userdata['session_logged_in'] || (isset($HTTP_GET_VARS['admin']) && $userdata['session_logged_in'] && $userdata['user_level'] == ADMIN)) { $mx_page->page_title = $lang['Login']; --- 71,75 ---- // user not already logged in // ! if( !$userdata['session_logged_in'] || ($mx_request_vars->is_get('admin') && $userdata['session_logged_in'] && $userdata['user_level'] == ADMIN)) { $mx_page->page_title = $lang['Login']; *************** *** 82,86 **** $forward_page = ''; ! if( isset($HTTP_POST_VARS['redirect']) || isset($HTTP_GET_VARS['redirect']) ) { $forward_to = $HTTP_SERVER_VARS['QUERY_STRING']; --- 82,86 ---- $forward_page = ''; ! if ($mx_request_vars->is_request('redirect')) { $forward_to = $HTTP_SERVER_VARS['QUERY_STRING']; *************** *** 116,120 **** $s_hidden_fields = '<input type="hidden" name="redirect" value="' . $forward_page . '" />'; ! $s_hidden_fields .= (isset($HTTP_GET_VARS['admin'])) ? '<input type="hidden" name="admin" value="1" />' : ''; //mx_make_jumpbox($phpbb_root_path . 'viewforum.'.$phpEx); --- 116,120 ---- $s_hidden_fields = '<input type="hidden" name="redirect" value="' . $forward_page . '" />'; ! $s_hidden_fields .= $mx_request_vars->is_get('admin') ? '<input type="hidden" name="admin" value="1" />' : ''; //mx_make_jumpbox($phpbb_root_path . 'viewforum.'.$phpEx); *************** *** 123,127 **** 'USERNAME' => $username, ! 'L_ENTER_PASSWORD' => (isset($HTTP_GET_VARS['admin'])) ? $lang['Admin_reauthenticate'] : $lang['Enter_password'], 'L_SEND_PASSWORD' => $lang['Forgotten_password'], --- 123,127 ---- 'USERNAME' => $username, ! 'L_ENTER_PASSWORD' => $mx_request_vars->is_get('admin') ? $lang['Admin_reauthenticate'] : $lang['Enter_password'], 'L_SEND_PASSWORD' => $lang['Forgotten_password'], Index: common.php =================================================================== RCS file: /cvsroot/mxbb/core/common.php,v retrieving revision 1.78 retrieving revision 1.79 diff -C2 -d -r1.78 -r1.79 *** common.php 7 Feb 2008 01:39:38 -0000 1.78 --- common.php 9 Feb 2008 12:52:36 -0000 1.79 *************** *** 26,33 **** //define( 'DEBUG', 1 ); // [Admin Option] Show Footer debug stats - Actually set in phpBB/includes/constants.php //define( 'DEBUG_EXTRA', 1 ); // [Admin Option] Show memory usage. Show link to full SQL debug report in footer. Beware, this makes the page slow to load. For debugging only. ! //error_reporting(E_ALL); //ini_set( 'display_errors', '1' ); ! error_reporting (E_ERROR | E_WARNING | E_PARSE); // This will NOT report uninitialized variables ! include($mx_root_path . 'modules/mx_shared/ErrorHandler/prepend.php'); // For nice error output // ================================================================================ --- 26,33 ---- //define( 'DEBUG', 1 ); // [Admin Option] Show Footer debug stats - Actually set in phpBB/includes/constants.php //define( 'DEBUG_EXTRA', 1 ); // [Admin Option] Show memory usage. Show link to full SQL debug report in footer. Beware, this makes the page slow to load. For debugging only. ! error_reporting(E_ALL & ~E_NOTICE); //ini_set( 'display_errors', '1' ); ! //error_reporting (E_ERROR | E_WARNING | E_PARSE); // This will NOT report uninitialized variables ! //include($mx_root_path . 'modules/mx_shared/ErrorHandler/prepend.' . $phpEx); // For nice error output // ================================================================================ *************** *** 131,134 **** --- 131,135 ---- // PHP5 with register_long_arrays off? + /* if (@phpversion() >= '5.0.0' && (!@ini_get('register_long_arrays') || @ini_get('register_long_arrays') == '0' || strtolower(@ini_get('register_long_arrays')) == 'off')) { *************** *** 147,151 **** } } ! // Protect against GLOBALS tricks if (isset($HTTP_POST_VARS['GLOBALS']) || isset($HTTP_POST_FILES['GLOBALS']) || isset($HTTP_GET_VARS['GLOBALS']) || isset($HTTP_COOKIE_VARS['GLOBALS'])) --- 148,152 ---- } } ! */ // Protect against GLOBALS tricks if (isset($HTTP_POST_VARS['GLOBALS']) || isset($HTTP_POST_FILES['GLOBALS']) || isset($HTTP_GET_VARS['GLOBALS']) || isset($HTTP_COOKIE_VARS['GLOBALS'])) |