Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Reschke <lukas@owncloud.com>2014-09-11 16:14:02 +0400
committerMorris Jobke <hey@morrisjobke.de>2014-09-17 15:17:52 +0400
commit6d3757f8648cb94b2ba04c6a5bfbc9dd1493103b (patch)
tree0cef084c3140b52a4ced70acc6ede3eb52cf33ab /index.php
parent45b17207ccf03703d4d6c3925f5405f52579aee5 (diff)
Do not show exception to the end-user
Log the error instead of potentially leaking sensitive information
Diffstat (limited to 'index.php')
-rwxr-xr-xindex.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/index.php b/index.php
index 061391892fe..88d5733cb37 100755
--- a/index.php
+++ b/index.php
@@ -33,6 +33,9 @@ try {
//show the user a detailed error page
OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE);
OC_Template::printExceptionErrorPage($ex);
+} catch (\OC\HintException $ex) {
+ OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE);
+ OC_Template::printErrorPage($ex->getMessage(), $ex->getHint());
} catch (Exception $ex) {
\OCP\Util::logException('index', $ex);