Файл: header/enter.inc.php
Строк: 47
<?php
If (!defined("anybody")){
if (!isset($_USER)){
// Блокировка
if ($_SESSION['block']) {
$_SESSION['block'] = $_SESSION['block'] + 1;
} else {
$_SESSION['block'] = 1;
}
//
echo '
<div class="downsw"><a href="/index.php'.$_zapros.'mode=lost"><font color="#FF0000"><small>Забыли пароль?</small></font></a></div>
<center>'.$pass.'<form action="enter.php?mode=enter" method="get"><br/>
Логин:<br/>
<input type="text" name="login" class="do_button" maxlength="'.lenght_login.'" value=""/><br/>
Пароль:<br/>
<input type="password" name="password" class="do_button" maxlength="'.lenght_password.'" value=""/><br/>
<input type="submit" class="button" value="Вход" /> <br />
<br />
</center>';
include "header/end.inc.php";
}
}
function xoring($String,$Seq)
{
$Salt='QwErTyUiOpAsDf123%#';
$StrLen = strlen($String);
$Gamma = '';
while (strlen($Gamma)<$StrLen)
{
$Seq = pack("H*",sha1($Gamma.$Seq.$Salt));
$Gamma.=substr($Seq,0,8);
}
return $String^$Gamma;
}
if(isset($_POST['img_code']) and $_SESSION['codes'] == $_POST['img_code']) $_SESSION['is_auth'] = 1;
if(!empty($_SESSION['codes']) and empty($_SESSION['is_auth']))
{
if(preg_match("#enter#",$_SERVER['REQUEST_URI']))
$_GET['mode'] = 'enter';
else
{
header('location: enter.php?mode=enter');
exit;
}
}
?>