mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-13 07:24:13 +01:00
Fix for Trac#627: Don't log the parameters in the call stack in case of exception to protect sensitive data.
SVN:trunk[2476]
This commit is contained in:
@@ -373,8 +373,15 @@ class ApplicationInstaller
|
||||
'percentage-completed' => 100,
|
||||
);
|
||||
|
||||
SetupPage::log_error('An exception occurred: '.$e->getMessage());
|
||||
SetupPage::log("Stack trace:\n".$e->getTraceAsString());
|
||||
SetupPage::log_error('An exception occurred: '.$e->getMessage().' at line '.$e->getLine().' in file '.$e->getFile());
|
||||
$idx = 0;
|
||||
// Log the call stack, but log the parameters since they may contain passwords or other sensitive data
|
||||
SetupPage::log("Call stack:");
|
||||
foreach($e->getTrace() as $aTrace)
|
||||
{
|
||||
SetupPage::log("#$idx {$aTrace['file']}({$aTrace['line']}): {$aTrace['function']}(...)");
|
||||
$idx++;
|
||||
}
|
||||
}
|
||||
return $aResult;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user