https://github.com/007tickooayush/ftp-rustified
A File Transfer Protocol (FTP) server made with Rust programming language using tokio library.
https://github.com/007tickooayush/ftp-rustified
rust rust-lang serde serde-json tokio tokio-io
Last synced: about 2 months ago
JSON representation
A File Transfer Protocol (FTP) server made with Rust programming language using tokio library.
- Host: GitHub
- URL: https://github.com/007tickooayush/ftp-rustified
- Owner: 007tickooayush
- Created: 2024-09-06T11:52:59.000Z (9 months ago)
- Default Branch: master
- Last Pushed: 2024-11-29T15:40:43.000Z (6 months ago)
- Last Synced: 2025-02-01T01:36:30.580Z (4 months ago)
- Topics: rust, rust-lang, serde, serde-json, tokio, tokio-io
- Language: Rust
- Homepage:
- Size: 316 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# FTP Server Project
### NOTE: *The project currently supports only gFTP FTP client and has only a few FTP commands and is a work in progress. The TLS and SSL support is not implemented yet.*
## Overview
This project is an FTP server implemented in Rust. It supports various FTP commands and provides functionalities for file transfer, directory management, and user authentication. The server is designed to handle multiple clients concurrently using asynchronous programming with `tokio`.
## Features
- **File Transfer**: Upload and download files.
- **Directory Management**: Create, delete, and list directories.
- **User Authentication**: Basic user authentication.
- **Asynchronous Handling**: Efficient handling of multiple clients using `tokio`.## Dependencies
The project uses the following dependencies:
- `tokio`: Asynchronous runtime for Rust.
- `serde`: Serialization and deserialization framework.
- `dotenv`: Load environment variables from a `.env` file.## FTP Commands
### USER
**Description**: Specify the user for authentication.
**Usage**: `USER `
**Example**:
USER anonymous
### PASS
**Description**: Specify the password for authentication.
**Usage**: `PASS `
**Example**:
PASS guest
### QUIT
**Description**: Terminate the connection.
**Usage**: `QUIT`
**Example**:
QUIT
### RETR
**Description**: Retrieve a file from the server.
**Usage**: `RETR `
**Example**:
RETR example.txt
### STOR
**Description**: Store a file on the server.
**Usage**: `STOR `
**Example**:
STOR example.txt
### DELE
**Description**: Delete a file from the server.
**Usage**: `DELE `
**Example**:
DELE example.txt
### RMD
**Description**: Remove a directory.
**Usage**: `RMD `
**Example**:
RMD /example_directory
### MKD
**Description**: Create a directory.
**Usage**: `MKD `
**Example**:
MKD /example_directory
### PWD
**Description**: Print the current working directory.
**Usage**: `PWD`
**Example**:
PWD
### LIST
**Description**: List files in the current directory.
**Usage**: `LIST`
**Example**:
LIST
### SIZE
**Description**: Return the size of a file.
**Usage**: `SIZE `
**Example**:
SIZE example.txt
Ensure that you have a `.env` file with the necessary environment variables, such as `ROOT_DIR` for the server's root directory.
## Usage
To run the server, use the following command:
```bash
cargo run
```