mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-24 17:04:14 +01:00
only send password (or hash) to client-side, if explicitly requested
This commit is contained in:
parent
64017370cd
commit
c68b8cc42d
@ -58,11 +58,11 @@ class Password extends Etemplate\Widget\Textbox
|
||||
$preserv =& self::get_array(self::$request->preserv, $form_name, true);
|
||||
$preserv = (string)$value;
|
||||
|
||||
if (!empty($value) && ((array_key_exists('viewable', $this->attrs) && $this->attrs['viewable'] === 'false') || $plaintext))
|
||||
// only send password (or hash) to client-side, if explicitly requested
|
||||
if (!empty($value) && (!array_key_exists('viewable', $this->attrs) || !in_array($this->attrs['viewable'], ['1', 'true', true], true)))
|
||||
{
|
||||
$value = str_repeat('*', strlen($preserv));
|
||||
}
|
||||
//$value = str_repeat('*', strlen($preserv));
|
||||
}
|
||||
}
|
||||
|
||||
@ -146,4 +146,4 @@ class Password extends Etemplate\Widget\Textbox
|
||||
$response->data($decrypted);
|
||||
}
|
||||
}
|
||||
Etemplate\Widget::registerWidget(__NAMESPACE__.'\\Password', array('passwd'));
|
||||
Etemplate\Widget::registerWidget(__NAMESPACE__.'\\Password', array('passwd'));
|
Loading…
Reference in New Issue
Block a user