Skip to content

Asynchronousx/File-Transfer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

File-Transfer


A simple terminal-based multithreaded C application that allows two (or more) machine connected to the same local network
to communicate between them to send and receive files over the internet, using the TCP/IP socket paradigm.
This small project has been designed for personal use and it is therefore open to some future improvement.

Secure Networking

This project comes with a custom networking safe library. The library contains functions to control efficiently the data
passage over the network, the handling of common socket errors and the definition of custom data structure to organize
the workflow of the socket definition, building and initialization.

Installing

You can both download and compile from scratch the source code, or install it with the install script.

Installing with the script

Just download the repository, extract the file to a folder and run

foo@bar:~/File-Transfer$ ./install.sh

Installing from source code

As above, download the repo and run the make into each folder (Client/Server) to generate the executable.
Before compiling, you must specify the path of your Repository, both for the client and the server (they should be different)
within the first 3 lines of code of both the FTClient and FTServer, where the #DEFINE "PATHTODIR" is located. Just change "PATHTODIR" to your favorite directory, build it and run the executable.

Usage

Follow this guidelines to begin the file-trasnfer:

Installed with the script

if you have already ran the the install script, you can type the commands anywhere from the terminal to start the transfer.
Also, two folder are created into the Home folder: FileDownload & FileUpload
FileDownload is the folder that stores the files download from the server.
FileUpload is the folder where the file that the server should share are put.
Note: you can move this folder anywhere in your filesystem.

To begin, you can type

foo@bar:~$ ftserver

to start the server, and

foo@bar:~$ ftclient <Server IP to reach>

to start the client. Be sure to put the ip address of the server as the first argument.

Additional Note: Be sure to put something into the FileUpload, otherwise the client won't see anything.

Installed from source

after you run the make and specify the repository folder, both for the client and the server, you only need to start the exectuable:
To start the client

foo@bar:~$ ./FTClient <Server IP to reach>

and to start the server

foo@bar:~$ ./FTServer

About

A simple multithreaded C application that transfers files over a network

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published