BUG 10921 "When changing the password, the old password..." SOLVED

- When changing the password, the old password should be
  required (and verified)
- Problem solved, added a new field to validate the user, when changing
  the password (user's profile)
* Available from version ProcessMaker-2.0.46
This commit is contained in:
Luis Fernando Saisa Lopez
2013-03-25 15:57:35 +00:00
parent 1741af5292
commit 387a574b74
3 changed files with 98 additions and 37 deletions

View File

@@ -612,4 +612,19 @@ switch ($_POST['action']) {
$response['descriptionText'] = $span . $gif . $text . '</span>';
echo G::json_encode($response);
break;
case "passwordValidate":
$messageResultLogin = "";
$password = $_POST["password"];
$resultLogin = $RBAC->VerifyLogin($_SESSION["USR_USERNAME"], $password);
if($resultLogin == $_SESSION["USER_LOGGED"]) {
$messageResultLogin = "OK";
} else {
$messageResultLogin = "ERROR";
}
$response = array();
$response["result"] = $messageResultLogin;
echo G::json_encode($response);
break;
}

View File

@@ -31,6 +31,7 @@ $oHeadPublisher->addExtJsScript( 'users/users', true ); //adding a javascript fi
// $oHeadPublisher->addContent('users/users'); //adding a html file .html.
$oHeadPublisher->assign( 'USR_UID', $aFields['USR_UID'] );
$oHeadPublisher->assign( 'infoMode', true );
$oHeadPublisher->assign("EDITPROFILE", 1);
$oHeadPublisher->assign( 'canEdit', $canEdit );
$oHeadPublisher->assign( 'MAX_FILES_SIZE', ' (' . $UPLOAD_MAX_SIZE . ') ' );
$oHeadPublisher->assign( 'MODE', '' );