SOLVED xmlapi.php stopped working

maheshbisen

Registered
Aug 31, 2018
4
1
3
Gondia
cPanel Access Level
Root Administrator
Hello,

I was able to get list of FTP account using xmlapi.php before few days [14th Aug 2018]. But it's throwing following error now.

Error
Code:
SimpleXMLElement Object ( [error] => Access denied [data] => SimpleXMLElement Object ( [result] => 0 [reason] => Access denied ) )

Script I am using -
Code:
include 'xmlapi.php';

$account = "xxxx";
$root_pass = 'xxxxx';
$ip = "xxx.xxx.xxx.xx";
$account = "xxxx";
$xmlapi = new xmlapi($ip);
$xmlapi->password_auth($account,$root_pass);
$list_ftpusers = $xmlapi->api2_query('Ftp', 'listftp',$account);
if($list_ftpusers){
    print_r($list_ftpusers);
}else{
    echo 'error';
}
Appreciate if anyone can help.
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,295
1,255
313
Houston