@@ -912,7 +912,7 @@ function saveLog($sSource, $sType, $sDescription)
|
||||
}
|
||||
|
||||
G::verifyPath(PATH_DATA . "log" . PATH_SEP, true);
|
||||
G::log(date("Y-m-d H:i:s") . " | $sObject | " . $sSource . " | $sType | " . $sDescription . "\n", PATH_DATA);
|
||||
G::log("| $sObject | " . $sSource . " | $sType | " . $sDescription . "\n", PATH_DATA);
|
||||
} catch (Exception $e) {
|
||||
//CONTINUE
|
||||
}
|
||||
|
||||
@@ -338,7 +338,7 @@ function saveLog($sSource, $sType, $sDescription)
|
||||
print date ('H:i:s') . " ($sSource) $sType $sDescription <br>\n";
|
||||
|
||||
G::verifyPath (PATH_DATA . 'log' . PATH_SEP, true);
|
||||
$message = date ('Y-m-d H:i:s') . '(' . $sSource . ') ' . $sDescription . "\n";
|
||||
$message = '(' . $sSource . ') ' . $sDescription . "\n";
|
||||
if ($sType == 'action') {
|
||||
G::log($message, PATH_DATA);
|
||||
}
|
||||
|
||||
@@ -517,7 +517,7 @@ function saveLog($sSource, $sType, $sDescription)
|
||||
print date ('H:i:s') . " ($sSource) $sType $sDescription <br>\n";
|
||||
|
||||
G::verifyPath (PATH_DATA . 'log' . PATH_SEP, true);
|
||||
$message = date ('Y-m-d H:i:s') . '(' . $sSource . ') ' . $sDescription . "\n";
|
||||
$message = '(' . $sSource . ') ' . $sDescription . "\n";
|
||||
if ($sType == 'action') {
|
||||
G::log($message, PATH_DATA);
|
||||
}
|
||||
|
||||
@@ -131,6 +131,20 @@ try {
|
||||
}
|
||||
}
|
||||
|
||||
//LOG Filed authentications
|
||||
$filedTimes = (defined(PPP_FAILED_LOGINS)) ? PPP_FAILED_LOGINS : 3;
|
||||
|
||||
if($_SESSION['FAILED_LOGINS'] > $filedTimes){
|
||||
$ip = G::getIpAddress();
|
||||
$browser = $_SERVER['HTTP_USER_AGENT'];
|
||||
|
||||
$path = PATH_DATA;
|
||||
$message = "| Many failed authentication attempts for USER: " . $usr . " | IP: " . $ip . " | WS: " . SYS_SYS . " | BROWSER: " .$browser ." | \n" ;
|
||||
$file = "loginFailed.log";
|
||||
|
||||
G::log($message, $path, $file);
|
||||
}
|
||||
|
||||
G::header("location: $loginUrl");
|
||||
die;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user