From 2a97390e6dddcfd46891905e5671e760b8a827b0 Mon Sep 17 00:00:00 2001 From: Nattfarinn Date: Thu, 1 Jun 2017 15:29:12 +0200 Subject: [PATCH] EZP-27399: Prevent password hash being returned in by rest (#870) * EZP-27399: Prevent password hash being returned in by rest * Fix CS comment (cherry picked from commit 64a2c4ed437061a82a43e676f9efed4944a499ce) --- Rest/UserFieldTypeProcessor.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Rest/UserFieldTypeProcessor.php b/Rest/UserFieldTypeProcessor.php index 78cf9e319..7ecfc482d 100644 --- a/Rest/UserFieldTypeProcessor.php +++ b/Rest/UserFieldTypeProcessor.php @@ -17,4 +17,11 @@ public function preProcessValueHash($incomingValueHash) return $incomingValueHash; } + + public function postProcessValueHash($outgoingValueHash) + { + unset($outgoingValueHash['passwordHash'], $outgoingValueHash['passwordHashType']); + + return $outgoingValueHash; + } }