Moved the Agents into their own repo. Kept the agent.pl just for reference

This commit is contained in:
Frank Harris 2025-09-11 13:27:32 -04:00
parent 22381be29a
commit 8680a02b13
18132 changed files with 0 additions and 2569420 deletions

View file

@ -1,36 +0,0 @@
<?php
error_reporting(0);
require('soap_config.php');
$client = new SoapClient(null, array('location' => $soap_location,
'uri' => $soap_uri,
'trace' => 1,
'exceptions' => 1));
$session_id = $client->login($username,$password);
$client_id = 0;
$username = $_GET['username'];
$password = $_GET['password'];
$dir = $_GET['dir'];
$uid = $_GET['uid'];
$gid = $_GET['gid'];
$params = array(
'server_id' => 1,
'parent_domain_id' => 1,
'username' => $username,
'password' => $password,
'quota_size' => -1,
'active' => 'y',
'uid' => $uid,
'gid' => $gid,
'dir' => $dir,
'quota_files' => -1,
'ul_ratio' => -1,
'dl_ratio' => -1,
'ul_bandwidth' => -1,
'dl_bandwidth' => -1
);
$ftp_id = $client->sites_ftp_user_add($session_id, $client_id, $params);
$client->logout($session_id);
if(!file_exists('ftp_users')) mkdir('ftp_users');
chdir('ftp_users');
file_put_contents($username, $ftp_id);
?>

View file

@ -1,15 +0,0 @@
<?php
error_reporting(0);
require('soap_config.php');
$client = new SoapClient(null, array('location' => $soap_location,
'uri' => $soap_uri,
'trace' => 1,
'exceptions' => 1));
$session_id = $client->login($username,$password);
chdir('ftp_users');
$username = $_GET['username'];
$ftp_user_id = file_get_contents($username);
$client->sites_ftp_user_delete($session_id, $ftp_user_id);
unlink($username);
$client->logout($session_id);
?>

View file

@ -1,24 +0,0 @@
<?php
//error_reporting(0);
require('soap_config.php');
$client = new SoapClient(null, array('location' => $soap_location,
'uri' => $soap_uri,
'trace' => 1,
'exceptions' => 1));
$session_id = $client->login($username,$password);
chdir('ftp_users');
$username = $_GET['username'];
$ftp_user_id = file_get_contents($username);
$ftp_user_record = $client->sites_ftp_user_get($session_id, $ftp_user_id);
if(isset($_GET['type']) AND $_GET['type'] == "detail")
{
foreach($ftp_user_record as $key => $value)
{
echo $key." : ".$value."\n";
}
}
else
{
echo $ftp_user_record['username']."\t".$ftp_user_record['dir']."/./\n";
}
?>

View file

@ -1,31 +0,0 @@
<?php
error_reporting(0);
require('soap_config.php');
$client = new SoapClient(null, array('location' => $soap_location,
'uri' => $soap_uri,
'trace' => 1,
'exceptions' => 1));
$session_id = $client->login($username,$password);
$client_id = 0;
chdir('ftp_users');
$username = $_GET['username'];
$ftp_user_id = file_get_contents($username);
//* Get the ftp user record
$ftp_user_record = $client->sites_ftp_user_get($session_id, $ftp_user_id);
if(isset($_GET['type']) AND $_GET['type'] == "password")
{
$ftp_user_record['password'] = $_GET['password'];
}
else
{
$settings = explode("\n",$_GET['password']);
foreach($settings as $setting)
{
list($key,$value) = explode("\t",$setting);
$ftp_user_record[$key] = $value;
}
}
$client->sites_ftp_user_update($session_id, $client_id, $ftp_user_id, $ftp_user_record);
$client->logout($session_id);
?>

View file

@ -1,7 +0,0 @@
<?php
$username = 'admin';
$password = 'admin';
$soap_location = 'http://127.0.0.1:8080/remote/index.php';
$soap_uri = 'http://127.0.0.1:8080/remote/';
?>