Archive for the ‘Batch FTP’ Category

FTP vs. FTPS

Sunday, March 2nd, 2014

What is FTP?

FTP is an acronym for File Transfer Protocol. It is a standard network protocol used to transfer files from one host to another host over a TCP-based network, such as the Internet.

FTP, you can update (delete, rename, move, and copy) files at a server. You need to logon to an FTP server. However, publicly available files are easily accessed using anonymous FTP.

Basic FTP support is usually provided as part of a suite of programs that come with TCP/IP. However, any FTP client program with a graphical user interface usually must be downloaded from the company that makes it.

What is FTPS?

FTPS (also known as FTP-ES, FTP-SSL and FTP Secure) is an extension to the commonly used File Transfer Protocol (FTP) that adds support for the Transport Layer Security (TLS) and the Secure Sockets Layer (SSL) cryptographic protocols. FTPS should not be confused with the SSH File Transfer Protocol (SFTP), an incompatible secure file transfer subsystem for the Secure Shell (SSH) protocol. It is also different from Secure FTP, the practice of tunneling FTP through an SSH connection.

– When establishing an SSL secure session, the following steps occur:
– Authenticate the server to the client.
– Allow the client and server to select the cryptographic algorithms, or ciphers, that they both support.
– Optionally authenticate the client to the server.
– Use public-key encryption techniques to generate shared secrets.

SSL is a commonly-used protocol for managing the security of a message transmission on the Internet. SSL uses the public-and-private key encryption system from RSA, which also includes the use of a digital certificate. The use of the digital certificate is the only difference between FTP and FTP/S. The FTP/S gateway supports standard FTP/S with clear control channel (CCC) enabled.

 Comparison

FTP

FTP classic

  • Plain FTP
  • Clear-text password sent over the network
  • Typically runs over TCP port 21
  • Defined by RFC 959 and 1123
  • Implemented in FTP/SSL component

FTPS

FTP over TLS/SSL

  • Often called ‘FTPS’
  • Often called ‘Secure FTP’
  • Plain FTP over TLS/SSL channel
  • Password is encrypted
  • Transfer is encrypted
  • Typically runs over TCP port 21 or 990
  • Defined by RFC 959, 1123, 4217 and 2228
  • Implemented in FTP/SSL component

 

 

 

 

 

 

 

 

 

 

 

Conclusion

SFTP and FTPS are both very secure with strong authentication options. In general, SFTP is technologically superior to FTPS. Since SFTP is much easier to port through firewalls, and FTPS due to this reason (needs a range of opts to be opened) puts additional security treats to the network, I believe SFTP is the clear winner in case you need a secure FTP for your application integration needs.

In our protocol evaluation, considering the above points, I feel we can go with SFTP for secured file transfer and can omit FTPS. FTPS is omitted not because it is not suitable, but because it does the same things as SFTP and is superior in many ways as opposed to FTPS. There are good reasons to support both FTPS and SFTP for secure file operations, and FTP for legacy devices. Organizations rarely have the option of supporting only one file transfer protocol, and solutions that supports all 3 are common-place today.

Guide to Windows Batch FTP

Saturday, March 27th, 2010

In order to access Window’s MS-DOS (Microsoft disk operating system) batch FTP, you need to first go to a DOS prompt, type FTP, and then hit enter. Once you’ve executed the program, then congratulations! You’ve just discovered the Windows-incorporated command-line FTP application that ships together with Windows NT or 95 and beyond. You can use this DOS-based FTP just like any other FTP client, except this time around, you need to at least have a basic understanding of how the old standard of MS-DOS works.

Scripting using FTP
FTP scripting is a relatively easy task. All you need to do is make a text document using FTP commands and use it to make your DOS-based FTP program do whatever you want without you manually entering each and every last command you need. For example, your script may contain the following commands:

open ftp.domain.com
mikesmith
t3n4y488
cd public_html
dir
get file.txt
bye

In order to execute the script if it were named “filetxtget.txt”, you should type:

ftp -s:filetxtget.txt

This script will help you login to the FTP site ftp.domain.com. Instead of waiting for a prompt for a username and password, the script itself will handle the details of your connection; you just need to substitute “mikesmith” for your username and “t3n4y488” for your password.

After you’ve logged in, the script will immediately access the public_html directory, retrieve a directory listing, and then utilize the “get” command to recover the file named file.txt. As soon as the file has been downloaded, the script will automatically log you off with the “bye” command. It’s that simple. At any rate, if you find Windows FTP’s scripting options sparse and limiting, consider using WinSCP.

Command Line Options for FTP
FTP has the following command-line options: “-v” represents the command that holds back the display of remote server responses. Meanwhile, “-d” activates the debugging feature, while “-i” deactivates interactive prompting whenever you’re doing numerous file transfers. Meanwhile, the “-s:filename” command (wherein “filename” represents the text file script you made) will automatically execute whatever commands are specified within your FTP script file after FTP starts.

Moreover, you shouldn’t confuse “-a” with “-A”. The lower case “-a” refers to the use of any local interface when you’re binding a data connection. In contrast, “-A” allows you to login to your FTP server anonymously. Furthermore, “-n” refers to auto-login suppression once an initial connection has been established, while “-w:buffer” refers to the override command for the default transfer buffer size of 4096. Finally, the “host” command allows you to know the IP address or host name of the remote host you’re connecting to.

Local FTP Commands
The local FTP commands you can use include the following: rmdir, open, lcd, close, rename, mput, help, cd, remotehelp, mls, hash, bye, verbose, recv, mkdir, glob, binary, user, quote, mget, get, bell, type, quite, mdir, disconnect, ascii, trace, pwd, mdelete, dir, append, status, put, ls, debug, ?, !, send, prompt, literal, and delete.

For many an administrator, having a built-in FTP program available on most DOS-based Windows operating systems is a very useful advantage. Unfortunately, it could also alienate modern PC enthusiasts because of their unfamiliarity with the old platform. Using FTP is hard enough as is, so adding the factor of it being in MS-DOS can make things a lot more complicated than they should be. Nevertheless, by educating yourself with basic FTP commands and streamlining the process with an FTP script, you should be able to use the program much easier and faster.