-
Notifications
You must be signed in to change notification settings - Fork 0
RedLeeder/5462Project1
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
_____________________ | Andrew Lee | | Subash Chebolu | | CSE5462 Project 1| | 09-11-16 README | | Updated: 10-20-16 | |___________________| ___________________ PROGRAM DESCRIPTION ___________________ Using everything built so far Project 1 focuses on creating a fully functional file transfer protocal using udp. We are to attempting to create everything from a timing system to figure out when to send packets as well as acknowledgements to make sure that the packet were received correctly. ====| ftps.c |===================================================== ftps.c contains the server code for recieving the file to be transfered and writing it to a local folder "recvd". The main changes were, as described above, replacing the bind, socket, send, and recv with BIND, SOCKET, SEND, and RECV which are user defined functions described in tcpapi.c. Once started, ftps.c will request a certain number of bytes from tcpds. ====| ftpc.c |===================================================== ftpc.c contains the client code for sending a local file, across the network (tcpdc -> Troll -> tcpds -> ftps) where it will be written to a new file by ftps.c. Like ftps.c, the main changes involved changing the bind, socket, send and recv with our user defined tcpapi.c functions BIND, SOCKET, SEND, and RECV. Once started with the proper parameters, ftpc.c will attempt to send a file through the network to the given server socket. ====| tcpapi.c |================================================== Same as for Lab03 it is our library file that contains the new methods that are responsible for the creation of sockets and sending of packets. The following functions are described in srbaclib.c: SEND - Converts the TCP send() to the UDP sendto() RECV - Converts the TCP recv() to the UDP recvfrom() BIND - Identical to bind() but assigns dest_addr ACCEPT - No functionality for Project 1 CONNECT - No functionality for Project 1 SOCKET - Identical to socket() ====| tcpapi.h |================================================== Header file that contains the function definitions for srbaclib.c ====| tcpds.c |=================================================== Contains the methods for receiving data from the ftps.c server that includes 1) The fact that the server is ready to recieve the file 2) The size of the buffer it is expecting It is responsible for recieving the packets from tcpdc.c and forwarding them to ftps.c where it will construct the recieved file. ====| tcpdc.c |=================================================== Contains the methods for sending packets from ftpc.c to the Troll which, acting like a network will forward them to the given address which is the tcpds.c. ====| Makefile |================================================== Contains the command line arguements for compiling and cleaning the Project 1 files. ====| crc32.c |================================================== File that contains code borrowed (more details in file) from the internet for doing checksumming so that garbled packets can be found and dealt with ====| crc32.h |================================================== File that contains the headers and function signatures for functions in crc32.c ====| sbuffer.h |================================================ Header file that contains relevent methods needed in ftps that pertain to the server circular buffer implementation, sbuffer.c ====| sbuffer.c |================================================ Contains the implementation for the circular server buffer used to store data. Implementation involves using a linked list to maintain circular buffer. ====| cbuffer.h |================================================ Header file that contains relevent methods needed in ftpc that pertain to the client circular buffer implementation, cbuffer.c ====| cbuffer.c |================================================ Contains the implementation for the circular client buffer used to store data. Implementation involves using a linked list to maintain circular buffer. ====| timerprocess.c |=========================================== Contains the logic and methods creating, maintaining, and printing the linked list containing the timers for packets. Interacted via timerDEMO.c which sends packets of 4 bytes that includes a flag byte (1 = Insert, 2 = Remove, 3 = Quit), a byteSeqNum byte, and 2 bytes containging two ints that represent the double time value. ====| timerDEMO.c |============================================== Contains the logic and hardcoded timer starting and canceling logic. Interacts with timerproccess.c via starttimer(), canceltimer() and quittimer(); ___________________ Running Instruction ___________________ ====| File Transfer |============================================= To successfully execute a file transfer using Project 1, one must complete the following steps. Note: cM = Client Machine sM = Server Machine 1) Compile the code by executing: | $ make clean | $ make 2) Run tcpds and tcpdc by executing in multiple terminals/machines | sM$ tcpds <client-IP> | cM$ tcpdc <server-IP> 3) Run troll by executing on the client machine | cM$ troll -t -x 0 -s 0 <local-PORT>(4000) 4) Run timerprocess by executing on the client maching | cM$ tp 4) Run ftps by executing the following on the server machine | sM$ ftps <server-PORT> 5) Run ftpc by executing the following on the client machine | cM$ ftpc <local-file-to-transfer> ====| Timer Demo |================================================ To successfully execute a timer demo using Project 1, one must complete the following steps. Note: cM = Client Machine sM = Server Machine 1) Compile the code by executing: | $ make clean | $ make 2) Run tp by executing in a terminal | sM$ tp <local-port> 3) Run td by executing in a terminal | cM$ td <remote-ip> <remote-port>
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published