Vergleich admin/index.php - 1.6.14 - 1.6.18

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 149Zeile 149
}
elseif($mybb->input['do'] == "login")
{

}
elseif($mybb->input['do'] == "login")
{

 
	// We have an adminsid cookie?
if(isset($mybb->cookies['adminsid']))
{
// Check admin session
$query = $db->simple_select("adminsessions", "sid", "sid='".$db->escape_string($mybb->cookies['adminsid'])."'");
$admin_session = $db->fetch_field($query, 'sid');

// Session found: redirect to index
if($admin_session)
{
admin_redirect("index.php");
}
}


	$user = validate_password_from_username($mybb->input['username'], $mybb->input['password']);
if($user['uid'])
{

	$user = validate_password_from_username($mybb->input['username'], $mybb->input['password']);
if($user['uid'])
{

Zeile 179Zeile 193
		);
$db->insert_query("adminsessions", $admin_session);
$admin_session['data'] = array();

		);
$db->insert_query("adminsessions", $admin_session);
$admin_session['data'] = array();

		$db->update_query("adminoptions", array("loginattempts" => 0, "loginlockoutexpiry" => 0), "uid='".intval($mybb->user['uid'])."'", 1);
my_setcookie("adminsid", $sid);

		$db->update_query("adminoptions", array("loginattempts" => 0, "loginlockoutexpiry" => 0), "uid='".intval($mybb->user['uid'])."'");
my_setcookie("adminsid", $sid, '', true);

		my_setcookie('acploginattempts', 0);
$post_verify = false;


		my_setcookie('acploginattempts', 0);
$post_verify = false;


Zeile 242Zeile 256

if($login_user['uid'] > 0)
{


if($login_user['uid'] > 0)
{

			$db->update_query("adminoptions", array("loginattempts" => "loginattempts+1"), "uid='".intval($login_user['uid'])."'", 1, true);

			$db->update_query("adminoptions", array("loginattempts" => "loginattempts+1"), "uid='".intval($login_user['uid'])."'", '', true);

		}

$loginattempts = login_attempt_check_acp($login_user['uid'], true);

		}

$loginattempts = login_attempt_check_acp($login_user['uid'], true);

Zeile 253Zeile 267
			// Have we set an expiry yet?
if($loginattempts['loginlockoutexpiry'] == 0)
{

			// Have we set an expiry yet?
if($loginattempts['loginlockoutexpiry'] == 0)
{

				$db->update_query("adminoptions", array("loginlockoutexpiry" => TIME_NOW+(intval($mybb->settings['loginattemptstimeout'])*60)), "uid='".intval($login_user['uid'])."'", 1);

				$db->update_query("adminoptions", array("loginlockoutexpiry" => TIME_NOW+(intval($mybb->settings['loginattemptstimeout'])*60)), "uid='".intval($login_user['uid'])."'");

			}

// Did we hit lockout for the first time? Send the unlock email to the administrator

			}

// Did we hit lockout for the first time? Send the unlock email to the administrator