Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unable to upload to correct FTPS folder if FTP site also exists
#1
Hello

I'm using Indy 10.6.0.516 on Delphi XE7.

I can get FTPS to upload to the correct folder using port 990 if there is no FTP site on the same IP. However, as soon as I set up an FTP site on port 21, then FTPS uploads now go to the FTP folder rather than the FTPS one.

Is it possible for Indy to work with FTPS when there are both FTP and FTPS sites on the same host? 

Here is my code:

Code:
               If IdFTP1.Connected then
                  IdFTP1.Disconnect;

               IdFTP1.Host:=FTP_HOST;
               IdFTP1.Port:=FTP_PORT; //990
               IdFTP1.Username:=FTP_USERID;
               IdFTP1.Password:=FTP_PASSWORD;
               IdFTP1.Passive:=True;

               IdSSLIOHandlerSocketOpenSSL1.Host:=FTP_HOST;
               IdSSLIOHandlerSocketOpenSSL1.Port:=FTP_PORT; //990
               IdSSLIOHandlerSocketOpenSSL1.DefaultPort:=FTP_PORT;

               IdSSLIOHandlerSocketOpenSSL1.SSLOptions.Method:=sslvSSLv23; 
               IdFTP1.IOHandler:=IdSSLIOHandlerSocketOpenSSL1;
               IdFTP1.UseTLS:=utUseExplicitTLS;

               IdFTP1.DataPortProtection:=ftpdpsPrivate;
               IdFTP1.Connect;
               IdFTP1.ChangeDir(FTP_FOLDER);

               IdFTP1.Put(zipSourceFile, zipDestinationFile);

Many thanks
Reply


Messages In This Thread
Unable to upload to correct FTPS folder if FTP site also exists - by Vintner - 05-10-2018, 03:37 PM

Forum Jump:


Users browsing this thread: 2 Guest(s)