summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b977131)
raw | patch | inline | side by side (parent: b977131)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 22 May 2007 13:34:10 +0000 (13:34 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 22 May 2007 13:34:10 +0000 (13:34 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6435 594d385d-05f5-0310-b6e9-bd551577e9d8
13 files changed:
diff --git a/html/combine.php b/html/combine.php
index b060ab9bc9e35dd94a6f9b0a3288b225efb2e622..2eadab8a960f68c97460d54146e8f9dbf7299378 100644 (file)
--- a/html/combine.php
+++ b/html/combine.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: combine.php called without session");
+ new log("security","all/all","",array(),"Error: combine.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getFAIscript.php b/html/getFAIscript.php
index 60e53d56a69f92c422b7fe4870d8636568fa345f..6c3cfeb37630b3db56c78f2e1164fa27206a6791 100644 (file)
--- a/html/getFAIscript.php
+++ b/html/getFAIscript.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getFAIScript.php called without session");
+ new log("security","fai","",array(),"Error: getFAIScript.php called without session") ;
header ("Location: index.php");
exit;
}
index 58bab226ba7b70656e4075a2cfe669b5eb7e9733..d853e5b9f49ec20e414be00da8c451add981f589 100644 (file)
--- a/html/get_attachment.php
+++ b/html/get_attachment.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: get_attachment.php called without session");
+ new log("security","glpi/all","",array(),"Error: get_attachment.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getbin.php b/html/getbin.php
index 6ac56b437d5d2104a2a8e8e2cbabd1278f9a8318..1817439c4b5b281d619eeec90a6e2dfa7e1303dc 100644 (file)
--- a/html/getbin.php
+++ b/html/getbin.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getbin.php called without session");
+ new log("security","unknown","",array(),"Error: getbin.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getfax.php b/html/getfax.php
index abf40da83d30930a9b6fa0abb11f49d4fc104a0c..374b7e25562388f96d86f7bfd7f71a9bd0d046f8 100644 (file)
--- a/html/getfax.php
+++ b/html/getfax.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getfax.php called without session");
+ new log("security","faxreport/faxreport","",array(),"Error: getfax.php called without session") ;
header ("Location: index.php");
exit;
}
/* User object present? */
if (!isset($_SESSION['fuserfilter'])){
- gosa_log ("Error: getfax.php called without propper session data");
+ new log("security","faxreport/faxreport","",array(),"getfax.php called without propper session data") ;
header ("Location: index.php");
exit;
}
/* Loading image */
if(!$handle = imagick_blob2image($data)) {
- gosa_log("Can't Load image");
+ new log("view","faxreport/faxreport","",array(),"Can't load fax image") ;
}
/* Converting image to PNG */
if(!imagick_convert($handle,"PNG")) {
- gosa_log("Can't Convert to PNG");
+ new log("view","faxreport/faxreport","",array(),"Can't convert fax image to png") ;
}
/* Resizing image to 420x594 and blur */
if(!imagick_resize($handle,420,594,IMAGICK_FILTER_GAUSSIAN,1)){
- gosa_log("imagick_resize failed");
+ new log("view","faxreport/faxreport","",array(),"Can't resize fax image") ;
}
/* Creating binary Code for the Image */
if(!$data = imagick_image2blob($handle)){
- gosa_log("Can't create blob for image");
+ new log("view","faxreport/faxreport","",array(),"Reading fax image image failed") ;
}
}
diff --git a/html/getkiosk.php b/html/getkiosk.php
index 1f8d59923e3fa12c8191bce6fe7947eb2a103d7f..cde88c5a063e006b555318ccace6625a294a5777 100644 (file)
--- a/html/getkiosk.php
+++ b/html/getkiosk.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getkiosk.php called without session");
+ new log("security","fai","",array(),"Error: getkiosk.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getldif.php b/html/getldif.php
index 0045c6757fbf6a1a749a56b9706caceb9dba88bc..6241d4fa7fec675f277a3c08afb78eb8b4918d60 100644 (file)
--- a/html/getldif.php
+++ b/html/getldif.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getldif.php called without session");
+ new log("security","all/all","",array(),"Error: getldif.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getvcard.php b/html/getvcard.php
index d17ff0ce30e97e999984bfe6cdf46a03ed56e75d..a1c68bc829a5259d3484a875d46bf5836700250a 100644 (file)
--- a/html/getvcard.php
+++ b/html/getvcard.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getvcard.php called without session");
+ new log("security","all/all","",array(),"Error: getvcard.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/getxls.php b/html/getxls.php
index 34c9936ba1ab49a6f96d7bc18e3d775b9d66ba76..de3607c82cc6fe4b4c7f874586080f4a314b5af3 100644 (file)
--- a/html/getxls.php
+++ b/html/getxls.php
/* Logged in? Simple security check */
if (!isset($_SESSION['ui'])){
- gosa_log ("Error: getxls.php called without session");
+ new log("security","all/all","",array(),"Error: getxls.php called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/helpviewer.php b/html/helpviewer.php
index d1828ac92086ba6f49b13232096f3f85baaa4ac6..b07cfb551157e7a32e4a050970fe30f93e3a4539 100644 (file)
--- a/html/helpviewer.php
+++ b/html/helpviewer.php
/* If no config object is found in the session, abort help */
if (!isset($_SESSION['config'])){
- gosa_log ("main.php called without session");
+ new log("security","all/all","",array(),"Help viewer called without session") ;
header ("Location: index.php");
exit;
}
diff --git a/html/index.php b/html/index.php
index 5468b8d9af55c75e99a522dc2b8e730474a67e66..e911823c56da99f972e0503674f209e4ed44361e 100644 (file)
--- a/html/index.php
+++ b/html/index.php
/* Load required includes */
require_once ("../include/php_setup.inc");
require_once ("functions.inc");
+require_once ("class_log.inc");
header("Content-type: text/html; charset=UTF-8");
function displayLogin()
if ($ui === NULL || $ui == 0){
$message= _("Please check the username/password combination.");
$smarty->assign ('nextfield', 'password');
- gosa_log ("Authentication failed for user \"$username\"");
+ new log("security","login","",array(),"Authentication failed for user \"$username\"") ;
} else {
/* Remove all locks of this user */
del_user_locks($ui->dn);
if ($expired == 1){
$message= _("Account locked. Please contact your system administrator.");
$smarty->assign ('nextfield', 'password');
- gosa_log ("Account for user \"$username\" has expired");
+ new log("security","login","",array(),"Account for user \"$username\" has expired") ;
} elseif ($expired == 3){
$plist= new pluglist($config, $ui);
foreach ($plist->dirlist as $key => $value){
if (preg_match("/\bpassword\b/i",$value)){
$plug=$key;
- gosa_log ("User \"$username\" password forced to change");
+ new log("security","login","",array(),"User \"$username\" password forced to change") ;
header ("Location: main.php?plug=$plug&reset=1");
exit;
}
}
/* Not account expired or password forced change go to main page */
- gosa_log ("User \"$username\" logged in successfully");
+ new log("security","login","",array(),"User \"$username\" logged in successfully") ;
header ("Location: main.php?global_check=1");
exit;
} else {
/* Go to main page */
- gosa_log ("User \"$username\" logged in successfully");
+ new log("security","login","",array(),"User \"$username\" logged in successfully") ;
header ("Location: main.php?global_check=1");
exit;
}
diff --git a/html/logout.php b/html/logout.php
index 6fb8bcc611d60db744d9c00a3e2dd4c458471912..5421e0e17254d115b72dd9acf360935c122d7e8c 100644 (file)
--- a/html/logout.php
+++ b/html/logout.php
del_user_locks($ui->dn);
/* Write something to log */
- gosa_log ("User \"".$ui->username."\" logged out");
+ new log("security","logout","",array(),"User \"".$ui->username."\" logged out") ;
}
/* If GET request is posted, the logout was forced by pressing the link */
diff --git a/html/main.php b/html/main.php
index ba5668e115d1e8400a7b9e77f07b9c5f296b3ef2..8a250fd0d005657412bd9ec31045fac178517ee5 100644 (file)
--- a/html/main.php
+++ b/html/main.php
/* Logged in? Simple security check */
if (!isset($_SESSION['config'])){
- gosa_log ("main.php called without session - logging out");
+ new log("security","login","",array(),"main.php called without session - logging out") ;
header ("Location: logout.php");
exit;
}
/* Check for uniqe ip address */
$ui= $_SESSION["ui"];
if ($_SERVER['REMOTE_ADDR'] != $ui->ip){
- gosa_log ("main.php called with session which has a changed IP address.", 3);
+ new log("security","login","",array(),"main.php called with session which has a changed IP address.") ;
header ("Location: logout.php");
exit;
}
*/
if($request_time > $max_life){
session_unset();
- gosa_log ("main.php called without session - logging out");
+ new log("security","login","",array(),"main.php called without session - logging out") ;
header ("Location: logout.php");
exit;
}
/* Check for register globals */
if (isset($global_check) && $config->data['MAIN']['FORCEGLOBALS'] == 'true'){
echo _("FATAL: Register globals is on. GOsa will refuse to login unless this is fixed by an administrator.");
- gosa_log ("Register globals is on. For security reasons, this should be turned off.");
+ new log("security","login","",array(),"Register globals is on. For security reasons, this should be turned off.") ;
session_destroy ();
exit ();
}
$plugin_dir= $plist->get_path($plug);
$_SESSION['plugin_dir']= $plugin_dir;
if ($plugin_dir == ""){
- gosa_log ("main.php called with invalid plug parameter \"$plug\"", 3);
+ new log("security","gosa","",array(),"main.php called with invalid plug parameter \"$plug\"") ;
header ("Location: logout.php");
exit;
}
$expired= ldap_expired_account($config, $ui->dn, $ui->username);
if ($expired == 2){
- gosa_log ("password for user \"$ui->username\" is about to expire");
+ new log("security","gosa","",array(),"password for user \"$ui->username\" is about to expire") ;
print_red(_("Your password is about to expire, please change your password"));
}
}