api token passwd problem
$oldpass = "123456aaaaa";
i use api token to execute whmapi1 passwd, to change a user password to alibaba123
[PHP]$query = "https://127.0.0.1:2087/json-api/passwd?api.version=1&user=userx&password='alibaba123'";[/PHP]
affter executed, the reponse:
[PHP](
[data] => Array
(
[app] => Array
(
[0] => system
[1] => ftp
[2] => mail
[3] => MySQL
)
)
[metadata] => Array
(
[result] => 1
[version] => 1
[command] => passwd
[output] => Array
(
[raw] => Password for "userx" has been changed.FTP (File Transfer Protocol) password change has been queued.
)
[reason] => Password changed for user "userx".
)
)[/PHP]
after that i can't use new password to login cpanel
the password didn't changed, i still can use old password to login
this is bug or i miss something? please advise
-
after that i can't use new password to login cpanel the password didn't changed, i still can use old password to login
Hello, Do you notice any output to /usr/local/cpanel/logs/error_log when running that WHM API 1 function? Thank you0 -
i already submit a ticket ,and it it json api bug internal case CPANEL-17323 0 -
Hello, Internal case CPANEL-17323 was closed as the issue was not reproducible. Are you intentionally including the single quotes with the new password so that they are part of the password? If not, refrain from placing the single quotes around the password when executing the function. Thank you. 0 -
i know the exactly problem already i execute the whmapi1 passwd at postwwwacct and ChangePasswd(Post) and my passwd process is faster than then cpanel change password process therefore the password had been overwritten by cpanel again i delay free seconds then the problem fixed 0 -
Hello, Thank you for sharing the outcome. 0
Please sign in to leave a comment.
Comments
5 comments