Note
You are viewing the documentation for an older release of Interworx (8.1). To see documentation for the current generally available release of Interworx, click here: 8.2.
Controller: /nodeworx/ftp¶
- Required Permissions
FTP
Action: autoRestart¶
- Added in Version
4.7.0-339
- Description
Set the FTP server auto-restart status.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No* |
1, 0 |
0 |
With this option on you can have FTP restarted automatically if FTP goes down unexpectedly. |
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
* indicates that it’s actually required, but probably already has a valid default value.
Action: fail¶
- Added in Version
4.7.0-339
- Description
Magic function - test for failure mechanism.
Action: isRunning¶
- Added in Version
4.7.0-339
- Description
Checks if the service is running or not.
Sample Output¶
array (
'status' => 0,
'payload' => true,
'reply_code' => 205,
)
Action: isRunningOnNode¶
- Added in Version
4.7.0-339
- Description
Checks if the service is running on a specific node (Clustering only).
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
string |
No* |
* indicates that it’s actually required, but probably already has a valid default value.
Action: killSessions¶
- Added in Version
4.8.0-393
- Description
Kill ftp sessions.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
struct (integer) |
Yes |
Action: listFtpSessions¶
- Added in Version
4.8.0-393
- Description
List Ftp Sessions.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
),
'reply_code' => 205,
)
Action: listGeneralName¶
- Added in Version
4.7.0-339
- Description
Lists the “normal” name - ie “web server” instead of “httpd”.
Sample Output¶
array (
'status' => 0,
'payload' => '##LG_FTPSERVER##',
'reply_code' => 205,
)
Action: listPortNumbers¶
- Added in Version
4.7.0-339
- Description
Lists a string of the port numbers that this service uses, comma-seperated.
Sample Output¶
array (
'status' => 0,
'payload' => '21, 24',
'reply_code' => 205,
)
Action: listPortNumbersArray¶
- Added in Version
4.7.0-339
- Description
Lists array of port numbers and ranges that this service uses.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
0 => 21,
1 => 24,
),
'reply_code' => 205,
)
Action: listRequiredPermissions¶
- Added in Version
4.7.0-339
- Description
Lists an array of permissions required to control the service.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
0 => 'FTP',
),
'reply_code' => 205,
)
Action: listServiceInfo¶
- Added in Version
4.7.0-339
- Description
Lists the service name, ports, page, and status.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
'id' => 'proftpd',
'name' => '##LG_FTPSERVER##',
'ports' => '21, 24',
'page' => '/nodeworx/ftp',
'ctrl' => '/nodeworx/ftp',
'is_running' => 1,
),
'reply_code' => 205,
)
Action: listServiceName¶
- Added in Version
4.7.0-339
- Description
Lists the service name - ie “httpd” instead of “web server”.
Sample Output¶
array (
'status' => 0,
'payload' => 'proftpd',
'reply_code' => 205,
)
Action: listServicePage¶
- Added in Version
4.7.0-339
- Description
Lists the page that controls the service.
Sample Output¶
array (
'status' => 0,
'payload' => '/nodeworx/ftp',
'reply_code' => 205,
)
Action: queryAutoRestart¶
- Added in Version
5.1.0-838
- Description
Displays the information available to the action “autoRestart”.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
'ftp_autorestart' => '0',
),
'reply_code' => 205,
)
Action: queryEditConf¶
- Added in Version
5.1.0-838
- Description
Displays the information available to the action “editConf”.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
'file' => '/etc/proftpd.conf',
'file_content' => '####
## InterWorx-CP Proftpd config
####
##
# Global Environment
##
ServerName "InterWorx-CP :: FTP Server"
ServerType standalone
ServerIdent on "FTP Server Ready"
PassivePorts 50000 51000
ListOptions -a
DefaultServer on
DeferWelcome on
SyslogLevel debug
UseReverseDNS off
UseFtpUsers off
IdentLookups off
WtmpLog off
ScoreboardFile /var/run/proftpd/proftpd-scoreboard
DisplayLogin /etc/motd
SetEnv TZ :/etc/localtime
PidFile /var/run/proftpd/proftpd.pid
##
# Basic Defaults
##
Port 21
Umask 022
##
# Timeouts
##
TimeoutLogin 120
TimeoutIdle 600
TimeoutNoTransfer 900
TimeoutStalled 3600
TimeoutSession 0
##
# security stuff
##
MaxInstances 30
RootLogin off
##
# The user/group we run as
##
User proftpd
Group proftpd
##
# Logging formats
##
TransferLog NONE
LogFormat default "%h %l %u %t \\"%m %f\\" %s %b"
LogFormat auth "%v [%P] %h %t \\"%r\\" %s"
LogFormat xfer "%h %l %u %t \\"%m %f\\" %s %b"
LogFormat byte "%u %b"
## system log
SystemLog /var/log/proftpd/auth.log
##
# Global settings
##
<Global>
##
# Basic stuff
##
DisplayLogin welcome.msg
DisplayChdir readme
ShowSymlinks on
AllowOverwrite on
TimesGMT off
AuthOrder mod_sql.c mod_auth_pam.c mod_auth_unix.c
##
# File upload/download resume
##
AllowRetrieveRestart on
AllowStoreRestart on
##
# SQL Authentication
##
SQLAuthenticate users*
SQLConnectInfo [email protected]:2307 iworx_ftp gQ74Q4Oo9QHz
SQLPasswordEngine on
SQLAuthTypes bcrypt Crypt
SQLUserWhereClause "1"
SQLMinUserUID 500
SQLMinUserGID 500
SQLDefaultUID 65533
SQLDefaultGID 65533
CreateHome off
SQLUserInfo users username password uid gid homedir shell
SQLGroupInfo groups groupname gid members
##
# Security stuff
##
MaxLoginAttempts 3
RequireValidShell off
MaxClients 25
## chroot everyone
DefaultRoot ~ !wheel
## hide root\'s stuff
<Directory />
HideUser root
HideGroup root
HideGroup wheel
</Directory>
##
# Logging
##
## xfer log
ExtendedLog /var/log/proftpd/xfer.log READ,WRITE xfer
</Global>
<IfModule mod_sftp.c>
<VirtualHost 0.0.0.0>
SFTPEngine on
SFTPLog /var/log/proftpd/sftp.log
ServerIdent off
# Configure the server to listen on the normal SSH2 port, port 22
Port 24
# Configure both the RSA and DSA host keys, using the same host key
# files that OpenSSH uses.
HostKeyGroup ssh_keys
SFTPHostKey /etc/ssh/ssh_host_rsa_key
#SFTPHostKey /etc/ssh/ssh_host_dsa_key
# Configure the file used for comparing authorized public keys of users.
SFTPAuthorizedUserKeys file:~/.sftp/authorized_keys
# Enable compression
SFTPCompression delayed
# Allow the same number of authentication attempts as OpenSSH.
#
# It is recommended that you explicitly configure MaxLoginAttempts
# for your SSH2/SFTP instance to be higher than the normal
# MaxLoginAttempts value for FTP, as there are more ways to authenticate
# using SSH2.
MaxLoginAttempts 6
</VirtualHost>
</IfModule>
<IfModule mod_tls.c>
TLSEngine on
TLSLog /var/log/proftpd/tls.log
TLSProtocol SSLv23 # this selects the latest crypt version
TLSOptions NoSessionReuseRequired # this is REALLY important for WinClients
# Are clients required to use FTP over TLS when talking to this server?
TLSRequired off
# Server\'s certificate
TLSRSACertificateFile /etc/pki/tls/certs/proftpd.pem
TLSRSACertificateKeyFile /etc/pki/tls/certs/proftpd.pem
# CA the server trusts
TLSCACertificateFile /etc/pki/tls/certs/proftpd.pem
# Authenticate clients that want to use FTP over TLS?
TLSVerifyClient off
</IfModule>
',
),
'reply_code' => 205,
)
Action: queryServerOptions¶
- Added in Version
5.1.0-838
- Description
Displays the information available to the action “serverOptions”.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
'maxinstances' => '30',
'maxclients' => '25',
'maxclientsperuser' => '0',
'timeoutlogin' => '120',
'timeoutidle' => '600',
'timeoutnotransfer' => '900',
'timeoutstalled' => '3600',
'timeoutsession' => '0',
'maxloginattempts' => '3',
'tlsrequired' => '0',
'showsymlinks' => '1',
'allowretrieverestart' => '1',
'allowstorerestart' => '1',
),
'reply_code' => 205,
)
Action: querySftpOptions¶
- Added in Version
5.1.0-838
- Description
Displays the information available to the action “sftpOptions”.
Sample Output¶
array (
'status' => 0,
'payload' =>
array (
'port' => '24',
'maxloginattempts' => '6',
'sftpengine' => '1',
),
'reply_code' => 205,
)
Action: reroute¶
- Added in Version
4.7.0-339
- Description
Action to re-route from the current controller to a different one.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
string |
Yes |
Index, Overview, Users, Lang, Apikey, Plugins, Twofactorauth, Notice, Siteworx, Shell, Packages, Backup, Import, Softaculous, Reseller, ResellerPackages, ResellerBandwidthhistory, Http, Phpextensions, Ftp, Sshd, MailMta, MailSmtp, MailSend, MailMda, MailMsa, MailDovecot, MailSpam, MailVirus, MailQueue, Mysql, MysqlRemote, MysqlPhpmyadmin, Dns, DnsZone, DnsRecord, DnsSync, Nfs, NfsExport, NfsMount, Health, Cron, Firewall, Ssl, Logs, Settings, Updates, Rrd, Ip, Ipv6, … |
Action: restart¶
- Added in Version
4.7.0-339
- Description
Restart the service.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
Action: restartOnNode¶
- Added in Version
4.7.0-339
- Description
Restarts the service on a specific node (Clustering only).
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
string |
No* |
* indicates that it’s actually required, but probably already has a valid default value.
Action: rrdGraph¶
- Added in Version
4.7.0-339
- Description
Set the FTP connections RRD graph display in the web interface.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No* |
1, 0 |
0 |
Use the dropdown to turn the FTP server activity graph on or off |
* indicates that it’s actually required, but probably already has a valid default value.
Action: serverOptions¶
- Added in Version
4.7.0-339
- Description
Update FTP server settings.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No* |
30 |
Sets the maximum number of child processes to be spawned |
|
|
integer |
No* |
25 |
The total number of FTP clients allowed to connect to the FTP server. |
|
|
integer |
No* |
0 |
The total number of FTP clients allowed to connect from a given user id. |
|
|
integer |
No* |
120 |
Sets the login timeout |
|
|
integer |
No* |
600 |
Sets the idle timeout |
|
|
integer |
No* |
900 |
Sets the connection without transfer timeout |
|
|
integer |
No* |
3600 |
Sets the timeout on stalled downloads |
|
|
integer |
No* |
0 |
Sets a timeout for an entire session |
|
|
integer |
No* |
3 |
Sets how many password attempts are allowed before disconnection |
|
|
integer |
No* |
1, 0 |
0 |
Toggle whether FTPS (secure FTP) is required on this server |
|
integer |
No* |
1, 0 |
1 |
Toggle the display of symlinks |
|
integer |
No* |
1, 0 |
1 |
Allow clients to resume uploads |
|
integer |
No* |
1, 0 |
1 |
Allow clients to resume downloads |
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
* indicates that it’s actually required, but probably already has a valid default value.
Action: sftpOptions¶
- Added in Version
4.9.0-427
- Description
Update SFTP server settings.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No* |
24 |
The port used for the SFTP service. |
|
|
integer |
No* |
6 |
Sets how many password attempts are allowed before disconnection |
|
|
integer |
No* |
1, 0 |
1 |
The current status of the SFTP engine. |
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
* indicates that it’s actually required, but probably already has a valid default value.
Action: start¶
- Added in Version
4.7.0-339
- Description
Start the service.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
Action: startOnBoot¶
- Added in Version
4.7.0-339
- Description
Set the FTP server start-on-boot status.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No* |
1, 0 |
1 |
If set to ‘Yes’, FTP will be automatically started when the server starts up |
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
* indicates that it’s actually required, but probably already has a valid default value.
Action: startOnNode¶
- Added in Version
4.7.0-339
- Description
Starts the service on a specific node (Clustering only).
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
string |
No* |
* indicates that it’s actually required, but probably already has a valid default value.
Action: stop¶
- Added in Version
4.7.0-339
- Description
Stop the service.
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
integer |
No |
1 |
Selecting this option causes the action to be replayed on all nodes of the cluster automatically, as if you had logged in to each node manually |
Action: stopOnNode¶
- Added in Version
4.7.0-339
- Description
Stops the service on a specific node (Clustering only).
Input Parameters¶
Name |
Type |
Required? |
Example Values |
Default Values |
Notes |
|---|---|---|---|---|---|
|
string |
No* |
* indicates that it’s actually required, but probably already has a valid default value.
Action: wait¶
- Added in Version
8.1.3-2998
- Description
Magic function - used to simulate a long-running process
Action: win¶
- Added in Version
4.7.0-339
- Description
Magic function - test for testing success mechanism.