Skip to content

Commit

Permalink
Remove censoring of schema and prefix from debug()
Browse files Browse the repository at this point in the history
As per discussion in #cakephp the other day, `debug()` will automatically censor out a list of keys, including `prefix` and `schema`. These are useful to see in output for debugging prefix routing, and should not automatically be considered sensitive information.
  • Loading branch information
AshleyPinner committed Oct 15, 2015
1 parent a6a699b commit 83b904b
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions lib/Cake/Utility/Debugger.php
Expand Up @@ -455,8 +455,6 @@ protected static function _highlight($str) {
* - host
* - database
* - port
* - prefix
* - schema
*
* This is done to protect database credentials, which could be accidentally
* shown in an error message if CakePHP is deployed in development mode.
Expand Down Expand Up @@ -514,8 +512,6 @@ protected static function _export($var, $depth, $indent) {
* - host
* - database
* - port
* - prefix
* - schema
*
* @param array $var The array to export.
* @param int $depth The current depth, used for recursion tracking.
Expand All @@ -528,9 +524,7 @@ protected static function _array(array $var, $depth, $indent) {
'login' => '*****',
'host' => '*****',
'database' => '*****',
'port' => '*****',
'prefix' => '*****',
'schema' => '*****'
'port' => '*****'
);
$replace = array_intersect_key($secrets, $var);
$var = $replace + $var;
Expand Down

0 comments on commit 83b904b

Please sign in to comment.