A powerful command-line Python tool for secure, encrypted file transfers across networks
Featuring AES-256 encryption and HMAC integrity verification for professionals who demand privacy and security
Features β’ Installation β’ Usage β’ Security β’ Contributing
|
|
- π€ File Sender Mode - Host files securely for transfer
- π₯ File Receiver Mode - Connect and download encrypted files
- π Passphrase Protection - User-defined encryption keys
- π‘οΈ Zero Plaintext Storage - Files never stored unencrypted during transfer
SecureFileTransferApp/
βββ π client.py # Client-side file receiver
βββ π server.py # Server-side file sender
βββ π encryption.py # AES encryption/decryption module
βββ β
hmac_verify.py # HMAC integrity functions
βββ π οΈ utils.py # Key derivation & utility functions
βββ π requirements.txt # Python dependencies
βββ π README.md # This documentation
- Python 3.8 or higher
- pip package manager
- Clone the repository
git clone https://github.com/ZeroHack01/SecureFileTransferApp.git
cd SecureFileTransferApp
- Create virtual environment (recommended)
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
- Install dependencies
pip install -r requirements.txt
The application uses passphrase-based key derivation for maximum security:
from utils import derive_key
key = derive_key("your_secure_passphrase")
β οΈ Critical Security Note: Both sender and receiver must use the identical passphrase for successful encryption/decryption. Choose a strong, unique passphrase for each transfer session.
- Use at least 12 characters
- Include uppercase, lowercase, numbers, and symbols
- Avoid dictionary words or personal information
- Consider using a passphrase generator
Start the server to host files for secure transfer:
python server.py --port 4444 --key "your_secure_passphrase"
Parameters:
--port
: Network port to listen on (default: 4444)--key
: Encryption passphrase (must match receiver)
Connect to the server to download encrypted files:
python client.py --host 192.168.1.100 --port 4444 --key "your_secure_passphrase"
Parameters:
--host
: IP address of the server machine--port
: Network port to connect to (must match server)--key
: Decryption passphrase (must match sender)
-
On Sender Machine:
python server.py --port 4444 --key "MySecurePassphrase123!"
-
On Receiver Machine:
python client.py --host 192.168.1.100 --port 4444 --key "MySecurePassphrase123!"
graph LR
A[Original File] --> B[AES-256 Encryption]
B --> C[HMAC Generation]
C --> D[Network Transfer]
D --> E[HMAC Verification]
E --> F[AES-256 Decryption]
F --> G[Restored File]
Component | Implementation | Purpose |
---|---|---|
Encryption | AES-256 in CBC mode | Confidentiality protection |
Initialization Vector | Cryptographically random IV | Prevents pattern analysis |
Integrity Protection | SHA-256 HMAC | Detects tampering/corruption |
Key Derivation | SHA-256 hash function | Secure passphrase-to-key conversion |
Memory Safety | No plaintext persistence | Prevents data recovery attacks |
- Confidentiality: Files are encrypted with military-grade AES-256
- Integrity: HMAC ensures files haven't been tampered with
- Authentication: Passphrase-based access control
- Forward Security: Each transfer uses unique initialization vectors
|
|
|
|
We welcome contributions from the community! Here's how you can help:
Found a bug? Open an issue with:
- Detailed description
- Steps to reproduce
- System information
- Expected vs actual behavior
Have an idea? Start a discussion or submit a feature request!
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
- Follow PEP 8 style guidelines
- Add unit tests for new features
- Update documentation as needed
- Ensure backward compatibility
This project is licensed under the MIT License - see the LICENSE file for details.
MIT License - You're free to use, modify, and distribute this software
with attribution to the original author.
Made with β€οΈ for secure file transfers