Skip to content
This repository has been archived by the owner on Dec 14, 2023. It is now read-only.

Commit

Permalink
No longer passing through old password
Browse files Browse the repository at this point in the history
This is now picked up from config.php prior to any changes
No need to pass through at all and removed as its a security risk
  • Loading branch information
mattpass committed Jun 24, 2012
1 parent cb3f87d commit 0de026f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion lib/settings-screen.php
Expand Up @@ -90,7 +90,6 @@
<input type="password" name="accountPassword" onkeydown="showButton()"><br>
confirm password<br>
<input type="password" name="confirmPassword" onkeydown="showButton()"><br>
<input type="hidden" name="oldPassword" value="<?php echo $accountPassword; ?>">
<br>
restricted files/folders<br>
<input type="text" onkeydown="document.settings.changedFileSettings.value='true';showButton()" name="restrictedFiles" value="<?php for($i=0;$i<=count($restrictedFiles)-1;$i++) {echo $restrictedFiles[$i]; if ($i<count($restrictedFiles)-1) {echo ', ';};}; ?>"><br>
Expand Down
2 changes: 1 addition & 1 deletion lib/settings.php
Expand Up @@ -41,7 +41,7 @@ function numClean($var) {
if ($_POST['codeAssist']) {$codeAssist = "true";} else {$codeAssist = "false";};
if ($_POST['visibleTabs']) {$visibleTabs = "true";} else {$visibleTabs = "false";};
if ($_POST['lockedNav']) {$lockedNav = "true";} else {$lockedNav = "false";};
if ($_POST['accountPassword']!="") {$accountPassword = generateHash(strClean($_POST['accountPassword']));} else {$accountPassword = strClean($_POST['oldPassword']);};
if ($_POST['accountPassword']!="") {$accountPassword = generateHash(strClean($_POST['accountPassword']));};
$restrictedFiles = 'array("'.str_replace(', ','","',strClean($_POST['restrictedFiles'])).'")';
$bannedFiles = 'array("'.str_replace(', ','","',strClean($_POST['bannedFiles'])).'")';
$allowedIPs = 'array("'.str_replace(', ','","',strClean($_POST['allowedIPs'])).'")';
Expand Down

0 comments on commit 0de026f

Please sign in to comment.