BEST代写-线上编程学术专家

Best代写-最专业靠谱代写IT | CS | 留学生作业 | 编程代写Java | Python |C/C++ | PHP | Matlab | Assignment Project Homework代写

C++代写 | CSCI 460 Project 1: File Transfer Protocol (FTP) Client Software Application

C++代写 | CSCI 460 Project 1: File Transfer Protocol (FTP) Client Software Application

本次代写是使用C++开发FTP文件传输程序的一个project

Objectives

1. To learn how a computer network protocol is documented in a Request for Comments (RFC) by
Internet Engineering Taskforce (IETF) as an Internet Standard.

2. To understand File Transfer Protocol (FTP) from RFC 959.

3. To learn and use Unix Network or Socket programming API.

4. To implement FTP Client software according to Internet Standard outlined in RFC 959.

5. To implement FPT Client software using C++ programming language and Unix Network or Socket
programming API.

Specifications

You have been using File Transfer Protocol (FTP) to get or to store files from or to FTP servers.
You use a FTP Client software in your host computer to communicate with an FTP server. FTP
server runs a FTP Server software application. In this project, you are going to implement your
own FTP Client software application in C++ programming language using Unix Network or Socket
programming API.

FTP is a client-server protocol to transfer files to/from the servers. An FTP client sends FTP
request messages to an FTP server. FTP server interprets the request message, takes appropriate
action, and sends back response message to the client. RFC 959 describes FTP and its request
and response messages in detail. You need to read and understand RFC 959 to complete this
project. Although, RFC 959 describes many request messages, you need to implement only the
followings:

USER
PASS
PWD
CWD
CDUP
PASV
NLST
RETR
QUIT

Your FTP Client software must have a command-line user interface (UI) so that the users can
enter commands through this interface. User commands of your application have different
syntax than that of FTP request messages. User commands are more human readable. A user
command has one or more corresponding FTP request message(s). Your software must accept
and process following user commands.

help
user <username>
pass <password>
pwd
dir
cwd <dirname>
cdup
get <filename>
quit

Some of the user commands have an argument. For example, command user has an
argument <username>. A user command and its argument is always space separated.

– Command ‘help’ displays the list of commands supported by this software application, their
syntax, and meaning.

– Command ‘user’ sends username to the FTP server for authentication. You need to support
only one user with user name ‘csci460’ and password ‘460pass’.

– Command ‘pass’ sends the password to the FTP server for authentication.

– Command ‘pwd’ prints the current working directory of the FTP server.

– Command ‘dir’ lists the contents of the current working directory of the FTP server.

– Command ‘cwd’ changes the current working directory to another directory specified in the
argument. If the specified directory is beyond current working directory of FTP server, an
error is reported by the server.

– Command ‘cdup’ changes the current working directory to its parent directory. If the parent
directory is beyond server’s base directory, an error is reported by the server.

– Command ‘get’ fetches the specified file from the current working directory of FTP server. If
the specified file is not available an error is reported by the server.

– Command ‘quit’ informs FTP server that the client application is quitting, so that the server
can close the connection gracefully. It also closes the client connection gracefully and
terminates the software.

Your FTP client software application must interpret above user commands, translate them into
appropriate FTP request messages, send the FTP request messages to FTP server, receive the
response messages from the server, and present the response to the user in a user-friendly
manner.

FTP Client and Server communicate request and response messages over a control connection.
Some requests/responses involve a data transmission. For example, RETR request involves a data
transmission to transfer file content as the part of a successful response. FTP server uses a
separate connection for each data transmission. A data connection is opened on demand and
closed when a data transmission is complete. FTP server can operate either in active or in passive
mode. In active mode, FTP server opens the data connection with the client on demand. If the
client is behind a firewall, FTP active mode fails to open a data connection. In passive mode, when
a data connection is required the server opens a connection listener so that client can send
connection request to the listener and open a data connection. Client instructs the server to enter
into passive mode by sending a PASV request message to the server. The server opens the
connection listener on a port and sends the port number to the client in its PASV response. After
receiving the PASV response, the client retrieves listener port number and sends a connection
request to the listener port in order to open a data connection. In this project, you must
implement passive mode and your FTP client software application, must send a PASV request
before any data request, such as RETR and NLST.

bestdaixie

评论已关闭。