PDA

View Full Version : admincp/user.php


anno1986
01-22-2014, 02:18 PM
Changing the user password from admin panel does not same to work?!?


@@ -35,8 +35,8 @@
// A form has been submitted, we will be processing the request.
if($mysidia->input->post("pass1")){
$newsalt = codegen(15, 0);
- $password = passencr($username, $pass1, $newsalt);
- $mysidia->db->update("users", array("password" => $password), "uid='{$mysidia->input->get("uid")}'");
+ $password = passencr($user->username, $mysidia->input->post("pass1"), $newsalt);
+ $mysidia->db->update("users", array("password" => $password, "salt" => $newsalt), "uid='{$mysidia->input->get("uid")}'");

Hall of Famer
01-27-2014, 01:50 AM
umm it does not work? I will run a few test cases to see where the problem is, thx for pointing it out. This does not seem to be a Priority 2 level bug though, even if its confirmed.

anno1986
01-27-2014, 02:44 AM
It was not working for me.. Look at the if condition


if($mysidia->input->post("pass1"))


and than you are checking $pass1 which is not defined I think

$password = passencr($username, $pass1, $newsalt)


but I am not sure yet.. :-)