A high-performance Rust tool designed to transfer files and directories securely over TCP. This project utilizes native-tls for SSL/SSL encryption and indicatif for a real-time visual progress bar.
- 🔒 TLS/SSL Encryption: End-to-end encrypted data transmission using
native-tls. - 🔑 Password Authentication: Mandatory secure authentication (default:
12345) before any data transfer. - 📁 Recursive Directory Transfer: Send entire directory structures with nested files effortlessly.
- 📄 Dynamic Filenames: Preserves original filenames and directory hierarchies on the server side.
- 📊 Visual Progress Bar: Real-time progress indicator showing bytes sent, ETA, and transfer speed.
- 🔄 Persistent Client: The client remains running after each transfer for multiple independent uploads.
- ⚡ Multi-threaded Server: Handles multiple concurrent client connections using standard library threads.
Ensure you have the following installed on your system:
- Rust (latest stable version)
- OpenSSL: Required for TLS support (pre-installed on most Linux/macOS; on Windows, use
vcpkgor pre-built binaries).
The project relies on:
native-tls: Secure SSL/TLS communication.indicatif: Visual progress bars and counters.walkdir: Recursive directory traversal.rpassword: Secure, masked password entry.
-
Generate a Certificate: Run the provided PowerShell script in the project root to generate the required
identity.p12file:.\generate_cert.ps1
-
Start the Server:
cargo run --bin server
-
Run the Client:
cargo run --bin client
Client View:
Secure File Transfer Client Started.
Enter transfer password: *****
Enter the Absolute path of the file or directory to send (or type 'exit' to quit):
C:\Users\user\Documents\ProjectFiles
Connected to server. Sending 5 files...
✔ [00:00:04] [########################################] 12.45 MiB/12.45 MiB (0s)
All files sent
Server response: All files received successfully.
The default port and password can be modified in src/bin/server.rs:
const AUTH_PASSWORD: &str = "12345";
// ...
let listener = TcpListener::bind("127.0.0.1:8080")?;- Custom Port Flags: Allow setting port and address via CLI arguments.
- Compression: Implement Gzip/Zstd compression for faster transfers.
- GUI Interface: Build a graphical user interface for easier file selection.
This project is open-source and available under the MIT License.