Personal Technology Information

FTP - File Transfer Protocol Explained


File Transfer Protocol (FTP) is a protocol that is part of the TCP/IP suite. It is the standard for transferring large amounts of data from server to server and from servers to clients. There is a very good chance that you have downloaded files from FTP sites many times, though it may have seemed you were only downloading from a website. FTP allows you to transfer files over a variety of hosts with different operating systems and file systems. There are so many FTP servers on the Internet, some are private with secure logon names, other ones are public with anonymous logins.

This paper will give a very brief outline of how the FTP Protocol functions and give the basic commands used during an FTP session. Keep in mind that these commands are generally automatic and are executed by either an FTP Client application, or done via your web browser. Though these methods are generally quicker than manually connecting to an FTP, it doesn't mean we should ignore the background behind how the technology works.

The FTP Protocol uses two connections to transfer a file. Each of these connections is quite a bit different, but work in conjunction with each other. The first connection is the Control Connection, which as the name implies controls the connection in regards to initiating the data streams and executing the commands. The second type of connection is the Data Connection, this connection is the actual connection that passes the files back and forth between the client and server.

Control Connection:
The control connection starts in a normal client / server manner. The client does an active open connection to port 21 of the FTP server to establish the control connection. The server is listening on port 21 for any active queries. Please keep in mind that though the primary FTP port is designated as porn 21, many servers, especially private ones are running on non-standard ports. The control connection as I mentioned early is the connection that allows you to pass commands between the client and server. Commands that must be sent are ones like LIST, STOR, and RETR. Once you enter a command on the control connection, you initiate the data connection.

Data Connection:
The data connection is spawned each time a file is moved between the client and server. The Control connection initiates the transfer with the PORT command, this tells the server to open an active connection to the clients passive port. The port command is typically the IP address followed by a 16 bit port number. The PORT command is issued in the following fashion:

PORT 24,82,116,92,4,150

That command should spawn a response of: 200 PORT Command Successful

After the PORT command has been initiated and is successful the next command in the data connection will be issued from the control connection. As I mentioned before this is typically a LIST, RERT or STOR. I will outline the basic FTP commands below for reference.

FTP Commands (Basic):
ABOR - Abort command and any data transfers
LIST - List the directory contents
PASS password - Used during authentication of login
USER username - Used during authentication of login
QUIT - Logoff / Quit session
RETR filename - Retrieve file from serverSTOR filename - Send a file to the server
SYST - Show System information
TYPE - Set the type of data, for instance ASCII
PORT - n1,n2,n3,n4,n5,n6 ( 1-4 = ip address, 5-6 port data)
HELP - Will give you additional available commands and more information

Reply Codes:
Reply codes are simply confirmations of things happening. One example of a reply code was went we got "200 PORT Command Successful" there are a handful of other reply codes, though generally the main ones are as follows.

125: Data Connection Open Start Transfer
200: Command OK
221: Goodbye / Terminate Connection
252: Write Error
331: Username OK, Enter Password
425: Can't Open Data Connection
500: Syntax Error on Command
501: Syntax Error on Arguments

Client Applications:
There are many different clients for FTP, and really it's up to personal taste in the end. A couple of the major ones are CuteFTP and FlashFXP. Personally I use FlashFXP when I'm in the Windows Environment. Just go to a freeware website or search on the search engines for a FTP Client and try a few out!

Summary of FTP:
The File Transfer Protocol is a wonderful and useful standard that has helped move data around the world safely and reliably for years. Everyone uses it from uploading their website to their web server, backing up their data to an off-site location, sharing their pictures with friends, or disseminating large data files for scientific research!

For even more information on the FTP, check out RFC 959.

Ken Dennis
http://KenDennis-RSS.homeip.net/


MORE RESOURCES:

04/28/2024
The Best Binoculars to Zoom In on Real Life
Whether you’re bird-watching or baseball-spotting, we break down prices and specs to find the best pair for you.


more info


04/28/2024
The Best Sleeping Bags for Every Adventure
Whether you’re climbing peaks or taking the family to the local park, we’ve found the best sleeping bags for every temperature, budget, and camping expedition.


more info


04/28/2024
Our Favorite Digital Notebooks and Smart Pens
These nifty tools combine the ease of jotting notes by hand with the power of saving them digitally.


more info


04/28/2024
The Best Password Managers to Secure Your Digital Life
Keep your logins locked down with our favorite password management apps for PC, Mac, Android, iPhone, and web browsers.


more info


04/28/2024
How to Get Free Kindle Books With Your Library Card
All you need is an internet connection, a library card, and a good ebook reader to dive into your next page-turner.


more info


04/28/2024
I Tried These AI-Based Productivity Tools. Here’s What Happened
Hoping to make life easier, I tested six AI-powered tools meant to help me write better and work smarter.


more info


04/28/2024
The Mysterious ‘Dark’ Energy That Permeates the Universe Is Slowly Eroding
Physicists call the dark energy that drives the universe “the cosmological constant.” Now the largest map of the cosmos to date hints that this mysterious energy has been changing over billions of years.


more info


04/27/2024
The Best Sleeping Pads for Camping, Backpacking, and Travel
Whether you’re snoozing in a campground or schlepping up to an alpine valley, these are the best pads we’ve found for resting your weary bones.


more info


04/27/2024
The Best Robot Vacuums to Keep Your Home Clean
Whether you’re up against pet hair or you want to splurge on a high-end laser-guided robot vacuum, we have the perfect pick for you.


more info


04/27/2024
Get the Most Out of Your iPad With These Accessories
These are some of our favorite stands, cases, keyboards, and styli, no matter which Apple tablet you have.


more info


04/27/2024
7 Spring Albums That You Don’t Need to Fight About Online
New music from Maggie Rogers, Tyla, Brittany Howard, and SchoolBoy Q showcase distinct artistic evolutions.


more info


04/27/2024
Autocomplete Interview
Autocomplete Interview - Is Ice Cube a nice guy? Do astronauts really drink their own pee? Does Gerard Butler still surf? The internet searches for answers and WIRED goes right to the source for the answer.


more info


04/27/2024
Meta’s Ray-Ban Smart Shades Get a Fresh Blast of AI
Plus: Leaked details tell us more about the new Google Pixel 8A, Freitag’s environmentally conscious bag is entirely recyclable, and it’s time to unpack a whole bunch of tech acronyms.


more info


04/27/2024
1 in 3 Americans Live in Areas With Dangerous Air Pollution
Climate change is increasing the number of days people are exposed to hazardous pollution, affecting already disadvantaged communities the most.


more info


04/27/2024
School Employee Allegedly Framed a Principal With Racist Deepfake Rant
This week in cybersecurity news: Google holds off on killing cookies, Samourai Wallet founders get arrested, GM stops its driver surveillance program, and a school principal's racist rant is revealed to be a deepfake.


more info


04/27/2024
Russia Vetoed a UN Resolution to Ban Space Nukes
A ban on weapons of mass destruction in orbit has stood since 1967. Russia apparently has other ideas.


more info


04/26/2024
Roborock’s Robot Vacuums—Including WIRED’s Top Pick—Are on Sale Right Now
More like Robot Rock, am I right? (Sorry.) These are some of the best dust busters around, and they’re cheaper than usual.


more info


04/26/2024
Tesla Autopilot Was Uniquely Risky—and May Still Be
In an investigative report into crashes and deaths associated with Tesla Autopilot, federal regulators concluded that the system lacked standard protections.


more info


04/26/2024
The 33 Best Shows on Amazon Prime Right Now
From "Mr. and Mrs. Smith" to "Fallout," these are our picks for what you should be watching on the streamer.


more info


04/26/2024
The 17 Best Movies on Amazon Prime Right Now
From "Road House" to "Bottoms," these are the must-watch films on the streamer.


more info


04/26/2024
Decades of Garry’s Mod Nintendo Uploads Are Disappearing
Nintendo is once again flexing its copyright muscles by filing takedown requests for user-generated content on the popular game platform.


more info


04/26/2024
The Best Lubes for Every Occasion
For the most sensitive parts of the human body, friction is the enemy. Here’s how to keep it at bay.


more info


04/26/2024
Which Govee Smart Lighting Kit Should You Buy?
Govee makes some of the best affordable smart lights, but its enormous range can be overwhelming and confusing. Here’s how to choose the right fit for your home.


more info


04/26/2024
The Best USB-C Cables for Your Phone, Tablet, or Laptop
Unravel the tangled world of cords and find the ones you need to charge your gadgets and transfer data.


more info


04/26/2024
The Best Car Phone Mounts and Chargers
These mobile accessories will make your smartphone a better—and safer—road trip companion.


more info



home | site map | contact us