git.shiar.nl
/
minimedit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
nieuws: support image containers after article intro
[minimedit.git]
/
login
/
pass.inc.php
diff --git
a/login/pass.inc.php
b/login/pass.inc.php
index cb2427e2babfdc0c77b6fd79b4b7de5099dbda95..986b4c262a91d4b8e8515c14423f24726bb027a0 100644
(file)
--- a/
login/pass.inc.php
+++ b/
login/pass.inc.php
@@
-1,12
+1,12
@@
<?php
<?php
-function passform($user, $input = [])
+function passform(
&
$user, $input = [])
{
if (empty($user)) {
return "Log eerst (opnieuw?) in.";
}
$pwfile = "{$user['dir']}/.passwd";
{
if (empty($user)) {
return "Log eerst (opnieuw?) in.";
}
$pwfile = "{$user['dir']}/.passwd";
- if (!is_writable($pwfile)) {
+ if (
file_exists($pwfile) and
!is_writable($pwfile)) {
return "Het wachtwoord kan niet worden aangepast voor deze gebruiker.";
}
return "Het wachtwoord kan niet worden aangepast voor deze gebruiker.";
}
@@
-43,7
+43,7
@@
function passform($user, $input = [])
@unlink("{$user['dir']}/.token"); # invalidate reset token
@unlink("{$user['dir']}/.token"); # invalidate reset token
- $authhash = md5($
input['newpass']
);
+ $authhash = md5($
passstore
);
$user['auth'] = "{$user['name']}:$authhash";
if ($GLOBALS['User'] === $user) {
login_setcookie();
$user['auth'] = "{$user['name']}:$authhash";
if ($GLOBALS['User'] === $user) {
login_setcookie();