Skip to main content

FTP Replies

The server sends FTP replies over the TELNET connection in response to user FTP commands. The FTP replies constitute the acknowledgment or completion code (including errors). The FTP-server replies are formatted for human or program interpretation. Single line replies consist of a leading three-digit numeric code followed by a space, followed by a one-line text explanation of the code. For replies that contain several lines of text, the first line will have a leading three-digit numeric code followed immediately by the character "-" (Hyphen, ASCII code 45), and possibly some text. All succeeding continuation lines except the last are constrained NOT to begin with three digits; the last line must repeat the numeric code of the first line and be followed immediately by a space. For example:

100-First Line
Continuation Line
Another Line
100 Last Line

It is possible to nest (but not overlap) a reply withiin a multi-line reply. The same format for matched number-coded first and last lines holds.

The numeric codes are assigned by groups and for ease of interpretation by programs in a manner consistent with other protocols such as the RJE protocol. The three digits of the code are to be interpreted as follows:

  1. The first digit specifies type of response as indicated below:
0xx  These replies are purely informative and constitute
neither a positive nor a negative acknowledgment.

1xx Informative replies to status inquiries. These constitute
a positive acknowledgment to the status command.

2xx Positive acknowledgment of previous command or other
successful action.

3xx Incomplete information. Activity cannot proceed without
further specification and input.

4xx Unsuccessful reply. The request is correctly specified
but the server is unsuccessful in correctly fulfilling it.

5xx Incorrect or illegal command. The command or its
parameters were invalid or incomplete from a syntactic
viewpoint, or the command is inconsistent with a previous
command. The command in question has been completely
ignored.

6xx-9xx Reserved for future expansion.
  1. The second digit specifies the general category to which the response refers:
x00-x29  General purpose replies, not assignable to other
categories.

x3x Primary access. Informative replies to the "log-on"
attempt.

x4x Secondary access. The primary server is commenting on its
ability to access a secondary service.

x5x FTP results.

x6x RJE results.

x7x Mail Portocol results.

x8x-x9x Reserved for future expansion.
  1. The final digit specifies a particular message type. Since the code is designed for an automaton process to interpret, it is not necessary for every variation of a reply to have a unique number. Only the basic meaning of replies need have unique numbers. The text of a reply can explain the specific reason for that reply to a human user.

Each TELNET line delimited by a numeric code and the TELNET EOL (or group of text lines bounded by coded lines) that is sent by the server is intended to be a complete reply message. It should be noted that the text of replies is intended for a human user. Only the reply codes and in some instances the first line of text are intended for programs.

The assigned reply codes relating to FTP are:

000  Announcing FTP.
010  Message from system operator.
020  Exected delay.
030  Server availability information.
050  FTP commentary or user information.
100  System status reply.
110  System busy doing...
150  File status reply.
151  Directory listing reply.
200  Last command received correctly.
201  An ABORT has terminated activity, as requested.
202  Abort request ignored, no activity in progress.
230  User is "logged in".  May proceed.
231  User is "logged out".  Service terminated.
232  Logout command noted, will complete when transfer done.
233  User is "logged out".  Parameters reinitialized.
250  FTP file transfer started correctly.
251  FTP Restart-marker reply.
   Text is:  MARK yyyy = mmmm
      where 'yyyy' is user's data stream marker (yours)
      and mmmm is server's equivalent marker (mine)
   (Note the spaces between the markers and '=').
252  FTP transfer completed correctly.
253  Rename completed.
254  Delete completed.
257  Closing the data connection, transfer completed.
300  Connection greeting message, awaiting input.
301  Current command incomplete (no <CRLF> for long time).
330  Enter password.
331  Enter account (if account required as part of login sequence).
332  Login first, please.
400  This service not implemented.
401  This service not accepting users now, goodbye.
402  Command not implemented for requested value or action.
430  Log-on time or tries exceeded, goodbye.
431  Log-on unsuccessful.  User and/or password invalid.
432  User not valid for this service.
433  Cannot transfer files without valid account.  Enter account and
     resend command.
434  Log-out forced by operator action.  Phone site.
435  Log-out forced by system problem.
436  Service shutting down, goodbye.
450  FTP:  File not found.
451  FTP:  File access denied to you.
452  FTP:  File transfer incomplete, data connection closed.
453  FTP:  File transfer incomplete, insufficient storage space.
454  FTP:  Cannot connect to your data socket.
455  FTP:  File system error not covered by other reply codes.
456  FTP:  Name duplication; rename failed.
457  FTP:  Transfer parameters in error.
500  Last command line completely unrecognized.
501  Syntax of last command is incorrect.
502  Last command incomplete, parameters missing.
503  Last command invalid (ignored), illegal parameter combination.
504  Last command invalid, action not possible at this time.
505  Last command conflicts illegally with previous command(s).
506  Last command not implemented by the server.
507  Catchall error reply.
550  Bad pathname specification (e.g., syntax error).