CSCE 515 Computer Network Programming Project 1 - Prof. W. Xu, Study Guides, Projects, Research of Computer Science

An individual project for csce 515 computer network programming students in the fall 2008 semester. The project involves creating a client-server pair using socket programming in c for simple password verification. Students must implement a program that takes usernames and passwords as input, sends them to the server, and receives a success or failure message in response. The server must listen for client connections, verify the received username and password against a list of legitimate pairs, and send the appropriate response.

Typology: Study Guides, Projects, Research

Pre 2010

Uploaded on 09/02/2009

koofers-user-ocx
koofers-user-ocx 🇺🇸

3

(1)

10 documents

1 / 1

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CSCE 515 Computer Network Programming
Project 1, Due Date: September 24, 2008
Undergraduate level
Fall 2008
This is an individual project. In this project, you are required to use socket programming in C to implement a pair of
client and server that can achieve simple password verification. Your client will send a pair of username and
password to your server and your server will verify whether the pair of username and password is legitimate or not.
Assume the only legitimate pairs of usernames and passwords that will be accepted by your server are as follows.
username Password
Alice aaaaaaaaaa
Bob bbbbbbbbb
Cindy cccccccccc
David ddddddddd
Eve eeeeeeeeee
Frank ffffffffff
George gggggggggg
More specifically, your client and server need to achieve the following requirements:
1. Your program for client needs to take two arguments that specify the name of server and the port that it is
trying to connect to. Your program for server needs to take an argument that specifies the port that it is
listening to. (1 point)
2. Your server will start first and keep listening to the specified port. Your client will connect to the port that
your server is listening to, and a socket between your client and server is constructed. (1 point)
3. Your client will first prompt a welcome message that asks the user to enter a username using the keyboard.
This username will then be sent to the server. Then, your server, after receiving the username from your
client, will send an acknowledgment message to the client. (1 point)
4. Your client, after receiving the acknowledgment message from your server, will prompt a message that
asks the user to enter the corresponding password. This password will then be sent to the server. Then, your
server, after receiving the password from your client, will verify the received pair of username and
password against the list of legitimate pairs. If the result is positive, the server will send a success message
to the client. If the result is negative, the server will send a failure message to the client. (2 point)
5. Your client, after receiving the result message, will print out the result and close the socket. Your server
will close the socket following the client, and keep listening for the next client request. (1 point)
This warm-up project will count for 10 points toward your final grade. You need to submit your two programs, a
Makefile (1 point), and a README file (1 point) via the Dropbox named project01 before the due day. This project
is due on Sept. 24 at 11:59pm .
Remember a grade of zero will be given, if your programs cannot be compiled and executed on Unix/Linux
machines. You should report your projects in a short write up, README file. The README file should contain
following information: 0) your name; 1) the programming environment you used; 2) how to compile your programs;
3) how to execute your programs. The programs will be graded based on the amount of the required functionalities
that has been implemented (6 points), and the quality of the code (2 points).

Partial preview of the text

Download CSCE 515 Computer Network Programming Project 1 - Prof. W. Xu and more Study Guides, Projects, Research Computer Science in PDF only on Docsity!

CSCE 515 Computer Network Programming

Project 1, Due Date: September 24, 2008

Undergraduate level

Fall 2008

This is an individual project. In this project, you are required to use socket programming in C to implement a pair of client and server that can achieve simple password verification. Your client will send a pair of username and password to your server and your server will verify whether the pair of username and password is legitimate or not. Assume the only legitimate pairs of usernames and passwords that will be accepted by your server are as follows.

username Password Alice aaaaaaaaaa Bob bbbbbbbbb Cindy cccccccccc David ddddddddd Eve eeeeeeeeee Frank ffffffffff George gggggggggg

More specifically, your client and server need to achieve the following requirements:

  1. Your program for client needs to take two arguments that specify the name of server and the port that it is trying to connect to. Your program for server needs to take an argument that specifies the port that it is listening to. (1 point)
  2. Your server will start first and keep listening to the specified port. Your client will connect to the port that your server is listening to, and a socket between your client and server is constructed. (1 point)
  3. Your client will first prompt a welcome message that asks the user to enter a username using the keyboard. This username will then be sent to the server. Then, your server, after receiving the username from your client, will send an acknowledgment message to the client. (1 point)
  4. Your client, after receiving the acknowledgment message from your server, will prompt a message that asks the user to enter the corresponding password. This password will then be sent to the server. Then, your server, after receiving the password from your client, will verify the received pair of username and password against the list of legitimate pairs. If the result is positive, the server will send a success message to the client. If the result is negative, the server will send a failure message to the client. (2 point)
  5. Your client, after receiving the result message, will print out the result and close the socket. Your server will close the socket following the client, and keep listening for the next client request. (1 point)

This warm-up project will count for 10 points toward your final grade. You need to submit your two programs, a Makefile (1 point), and a README file (1 point) via the Dropbox named project01 before the due day. This project is due on Sept. 24 at 11:59pm.

Remember a grade of zero will be given, if your programs cannot be compiled and executed on Unix/Linux machines. You should report your projects in a short write up, README file. The README file should contain following information: 0) your name; 1) the programming environment you used; 2) how to compile your programs;

  1. how to execute your programs. The programs will be graded based on the amount of the required functionalities that has been implemented (6 points), and the quality of the code (2 points).