- A simple FTP server & client written in C.
- Created for a class assignment 🧠
- Build
make build
- Server
- When a server (myftpd) receives a request for a TCP connection request, it
forks()
and the child process accepts subsequent command messages from the client.
- When a server (myftpd) receives a request for a TCP connection request, it
./myftpd <dir>
- Client
- Once a TCP connection is established, a client (myftpc) displays the prompt "myFTP%" and waits for user input.
./myftpc <IP>
command | args | description |
---|---|---|
quit | – | quit the program |
pwd | – | print current directory |
cd | path | change current directory |
dir | path | list current directory |
lpwd | – | print client current directory |
lcd | path | change client current directory |
ldir | path | list client current directory |
get | path1 path2 | get the file of 'path1' from server and save to 'path2' |
put | path1 path2 | put file of 'path1' to server and save to 'path2' |
help | – | print help message |