Skip to content
Snippets Groups Projects
Unverified Commit 8f3820af authored by Jaime Pérez Crespo's avatar Jaime Pérez Crespo
Browse files

bugfix: The var_export() method is not always used for arrays.

parent 133fe513
No related branches found
No related tags found
No related merge requests found
......@@ -302,13 +302,15 @@ abstract class sspmod_ldap_Auth_Process_BaseFilter extends SimpleSAML_Auth_Proce
*/
public function var_export($value)
{
// Remove sensitive data
foreach ($value as $key => &$val) {
if ($key === 'ldap.password') {
$val = empty($val) ? '' : '********';
if (is_array($value)) {
// remove sensitive data
foreach ($value as $key => &$val) {
if ($key === 'ldap.password') {
$val = empty($val) ? '' : '********';
}
}
unset($val);
}
unset($val);
$export = var_export($value, true);
$lines = explode("\n", $export);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment