Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
entrix
WoWSimpleRegistration
Commits
43aa5b44
Unverified
Commit
43aa5b44
authored
May 24, 2019
by
Amin.MasterkinG
Committed by
GitHub
May 24, 2019
Browse files
Fix password change.
parent
e0be6896
Changes
1
Hide whitespace changes
Inline
Side-by-side
application/include/user.php
View file @
43aa5b44
...
...
@@ -139,7 +139,7 @@ class user
if
(
!
empty
(
$userinfo
[
"username"
]))
{
$Old_hashed_pass
=
strtoupper
(
sha1
(
strtoupper
(
$userinfo
[
"username"
]
.
":"
.
$_POST
[
"old_password"
])));
$hashed_pass
=
strtoupper
(
sha1
(
strtoupper
(
$userinfo
[
"username"
]
.
":"
.
$_POST
[
"password"
])));
if
(
$userinfo
[
"sha_pass_hash"
]
==
$Old_hashed_pass
)
{
if
(
strtoupper
(
$userinfo
[
"sha_pass_hash"
]
)
==
$Old_hashed_pass
)
{
database
::
$auth
->
update
(
"account"
,
[
"sha_pass_hash"
=>
$antiXss
->
xss_clean
(
$hashed_pass
),
"sessionkey"
=>
""
,
...
...
@@ -191,7 +191,7 @@ class user
if
(
!
empty
(
$userinfo
[
"username"
]))
{
$Old_hashed_pass
=
strtoupper
(
sha1
(
strtoupper
(
$userinfo
[
"username"
]
.
":"
.
$_POST
[
"old_password"
])));
$hashed_pass
=
strtoupper
(
sha1
(
strtoupper
(
$userinfo
[
"username"
]
.
":"
.
$_POST
[
"password"
])));
if
(
$userinfo
[
"sha_pass_hash"
]
==
$Old_hashed_pass
)
{
if
(
strtoupper
(
$userinfo
[
"sha_pass_hash"
]
)
==
$Old_hashed_pass
)
{
database
::
$auth
->
update
(
"account"
,
[
"sha_pass_hash"
=>
$antiXss
->
xss_clean
(
$hashed_pass
),
"sessionkey"
=>
""
,
...
...
@@ -263,4 +263,4 @@ class user
}
return
false
;
}
}
\ No newline at end of file
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment