EnsLib.FTP.Commonabstract class EnsLib.FTP.Common
Adapter that receives files via the FTP protocol.
The name of an existing SSL/TLS system configuration set to use for FTPS (Secure Socket Layer / Transport Layer Security, configured via the system portal's Security Management page).
This is for FTPS, meaning an encrypted connection to a normal FTP server.
If you append an asterisk (*) to the configuration name you enter, this adapter will use legacy FTPS mode. FTPS is defined by RFC4217 but some servers operate with a non-compliant variant which simply assumes that the command channel should use TLS. Earlier versions of this adapter worked only with this sort of non-compliant server. Append an asterisk to the SSL configuration name if you need to (continue to) work with this sort of server. Set this value to !SFTP to instead use the SFTP protocol to connect to a remote SFTP server. SFTP is which is a secure FTP-like protocol conducted through an SSH (Secure SHell) tunnel.
If you use !SFTP then:
- the UsePASV and ServerListStyle values will be ignored.
- the FTPPort value should ordinarily be set to 22.
- you must supply a Credentials value
- if you supply values for both SFTPPublicKeyFile and SFTPPrivateKeyFile the adapter will attempt key pair authentication. It will do this in conjunction with the username and password supplied via the Credentials setting, using the password in the Credentials as the passphrase for the private key.
- if you don't supply both KeyFile values the adapter will attempt only username/password authentication based on the Credentials setting.
Use Passive FTP mode: server returns a data port address and the client connects to it. Most firewalls are more tolerant of Passive mode FTP because both the control and data TCP connections are initiated by the client.
Connect to the FTP server and log in, setting the directory and transfer mode
Use this method, ..CreateTimestamp(), when naming files on the remote FTP server, use ##class(Ens.Util.File).CreateTimestamp() when naming local files.
Disconnect from the datasource
Selects Name As
%String, Type As %String, Size As %BigInt, DateCreated As %TimeStamp, DateModified As %TimeStamp, ItemName As %String, ItemDir As %String, SemaphoreName As %String
This query is a shadow of the FileSet query in %Library.File, using an interface to the Adapter and skipping directories The dirsOrNoDirs argument if 0 (the default) will exclude directory entries, or if 1 will return directory entries only.