Made by @acberton, @dguido1, @drotter120 & @justinpoblete
For CPSC 471 - Computer Communication at California State University Fullerton
Spring 21'
- This application allows a client to connect to an FTP server
- The FTP server will then allow the client to:
- Upload a file to the server
- Download an existing file from the server
- Close the FTP connection and exit program
- SPECIAL NOTE: When running through Tuffix, socket functions that retrieved addresses would be different (127.0.0.1 and 127.0.1.1). This caused connectivity issues and would recommend running on any another OS.
serv.py
cli.py
client-data.txt
and the uploads
subfolder containing server-data.txt
3. Open two terminals in your OS. One of these servers will be the server, and the other will be the client.
4. In one of your terminals run the serv.py
script using the following command:
6. Once both scripts are running, your client terminal will prompt you to enter one of four ftp commands:
-
Once a command is entered, the server will listen for the file name, open the data channel and finally respond accordingly to the command inputted by the client.
-
As noted above, when you are ready to close the session, simply type "close" in the ftp prompt of your client terminal.
- CPSC471-ftp-project
serv.py
- Handles server-side communication with FTP connectioncli.py
- Handles client-side communication with FTP connectionclient-data.txt
- This represents the default client datauploads
- This represents the server directory locationserver-data.txt
- This represents the default server data
As expected, the server only returns server-data.txt
, the default server data
Here we upload client-data.txt
to the server
i.e. client-data.txt
can now be found in uploads
Now the server returns server-data.txt
and also client-data.txt
since we just sent it to the server in the step above
Here we request and download server-data.txt
from the server to the clients computer
Thanks for reading!
If you like what you see give this repo
a star and share it with your friends.
Your support is greatly appreciated!