0 votes
by (260 points)
edited

Given a server address and port number, how do I determine if I need to use an SSL FTPS connection or a standard non-encrypted FTP connection?

Applies to: Rebex FTP/SSL

1 Answer

0 votes
by (147k points)
edited

If the port number is 990, use implicit SSL (FtpSecurity.Implicit). If the port number is 21, it's more complicated - it's either non-encrypted connection or it's secured using explicit SSL (FtpSecurity.Explicit). If unsure, establish a non-encrypted connection first and try to enable explicit SSL later by calling Ftp object's Secure method (if it throwns an FtpException, it means that explicit SSL is not possible, but you can still continue using the connection in standard non-encrypted mode.

(Finally, if the port number is 22, you need to use Rebex SFTP instead of Rebex FTP/SSL.)

...