Vergleich inc/class_core.php - 1.2.0 - 1.2.11

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 3Zeile 3
 * MyBB 1.2
* Copyright � 2006 MyBB Group, All Rights Reserved
*

 * MyBB 1.2
* Copyright � 2006 MyBB Group, All Rights Reserved
*

 * Website: http://www.mybboard.com
* License: http://www.mybboard.com/eula.html

 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/eula.html

 *

 *

 * $Id: class_core.php 2187 2006-09-02 13:48:31Z chris $

 * $Id: class_core.php 3387 2007-10-14 00:58:14Z chris $

 */

class MyBB {

 */

class MyBB {

Zeile 15Zeile 15
	 *
* @var string
*/

	 *
* @var string
*/

	var $version = "1.2";


	var $version = "1.2.11";


	/**
* The version code of MyBB we're running.
*
* @var integer
*/

	/**
* The version code of MyBB we're running.
*
* @var integer
*/

	var $version_code = 120;

	var $version_code = 1211;

	
/**
* The current working directory.

	
/**
* The current working directory.

Zeile 68Zeile 68
	
/**
* MyBB configuration.

	
/**
* MyBB configuration.

	 *
* @var array

	 *
* @var array

	 */
var $config = array();

	 */
var $config = array();

	
/**

	
/**

	 * The debug information.
*
* @var unknown_type

	 * The debug information.
*
* @var unknown_type

Zeile 82Zeile 82
	
/**
* The request method that called this page.

	
/**
* The request method that called this page.

	 *

	 *

	 * @var string.
*/
var $request_method = "";

/**

	 * @var string.
*/
var $request_method = "";

/**

	 * Variables that need to be clean.

	 * Variables that need to be cleaned.

	 *
* @var array
*/
var $clean_variables = array(
"int" => array("tid", "pid", "uid", "eid", "pmid", "fid", "aid")
);

	 *
* @var array
*/
var $clean_variables = array(
"int" => array("tid", "pid", "uid", "eid", "pmid", "fid", "aid")
);











/**
* Variables that are to be ignored from cleansing proccess
*
* @var array
*/
var $ignore_clean_variables = array();


	/**
* Using built in shutdown functionality provided by register_shutdown_function for < PHP 5?
*/

	/**
* Using built in shutdown functionality provided by register_shutdown_function for < PHP 5?
*/

Zeile 110Zeile 116
	function MyBB()
{
// Set up MyBB

	function MyBB()
{
// Set up MyBB

 
		$protected = array("_GET", "_POST", "_SERVER", "_COOKIE", "_FILES", "_SERVER", "_ENV", "GLOBALS");
foreach($protected as $var)
{
if($_REQUEST[$var] || $_FILES[$var] || $_COOKIE[$var])
{
die("Hacking attempt");
}
}

if(defined("IGNORE_CLEAN_VARS"))
{
if(!is_array(IGNORE_CLEAN_VARS))
{
$this->ignore_clean_variables = array(IGNORE_CLEAN_VARS);
}
else
{
$this->ignore_clean_variables = IGNORE_CLEAN_VARS;
}
}


// Determine Magic Quotes Status
if(get_magic_quotes_gpc())


// Determine Magic Quotes Status
if(get_magic_quotes_gpc())

Zeile 122Zeile 148
		set_magic_quotes_runtime(0);
@ini_set("magic_quotes_gpc", 0);
@ini_set("magic_quotes_runtime", 0);

		set_magic_quotes_runtime(0);
@ini_set("magic_quotes_gpc", 0);
@ini_set("magic_quotes_runtime", 0);

		

		

		// Determine input
$this->parse_incoming($_GET);
$this->parse_incoming($_POST);

		// Determine input
$this->parse_incoming($_GET);
$this->parse_incoming($_POST);

Zeile 168Zeile 194
	 * @param array The array of incoming variables.
*/
function parse_incoming($array)

	 * @param array The array of incoming variables.
*/
function parse_incoming($array)

	{
if(!is_array($array))
{
return;
}

foreach($array as $key => $val)
{

	{
if(!is_array($array))
{
return;
}

foreach($array as $key => $val)
{

			$this->input[$key] = $val;
}
}

			$this->input[$key] = $val;
}
}

Zeile 215Zeile 241
		foreach(array_keys($array) as $key)
{
unset($GLOBALS[$key]);

		foreach(array_keys($array) as $key)
{
unset($GLOBALS[$key]);

 
			global $$key;
unset($$key);

		}
}


		}
}


Zeile 228Zeile 256
		{
foreach($variables as $var)
{

		{
foreach($variables as $var)
{

 
				// If this variable is in the ignored array, skip and move to next
if(in_array($var, $this->ignore_clean_variables))
{
continue;
}

				if($type == "int" && isset($this->input[$var]) && $this->input[$var] != "lastposter")
{
$this->input[$var] = intval($this->input[$var]);

				if($type == "int" && isset($this->input[$var]) && $this->input[$var] != "lastposter")
{
$this->input[$var] = intval($this->input[$var]);

Zeile 269Zeile 302
				$message = "Your board has not yet been installed and configured. Please do so before attempting to browse it.";
break;
default:

				$message = "Your board has not yet been installed and configured. Please do so before attempting to browse it.";
break;
default:

				$message = "MyBB has experienced an internal error. Please contact the MyBB Group for support. <a href=\"http://www.mybboard.com\">MyBB Website</a>";

				$message = "MyBB has experienced an internal error. Please contact the MyBB Group for support. <a href=\"http://www.mybboard.net\">MyBB Website</a>";

		}
include MYBB_ROOT."inc/generic_error.php";
if($halt)

		}
include MYBB_ROOT."inc/generic_error.php";
if($halt)