- Complete rewrite of zenity-based bash script in Python - Modern tkinter GUI with Microsoft RDP Client-like design - Encrypted credential storage and connection management - Fixed STATUS_ACCOUNT_RESTRICTION authentication issues - Support for multiple monitors, sound, clipboard, drive sharing - Connection history and profile management - Keyboard shortcuts and professional interface - Comprehensive logging and error handling - Virtual environment auto-detection and setup - Full feature parity with original bash script - Enhanced security with Fernet encryption - Cross-platform compatibility and modern UX
180 lines
4.6 KiB
Markdown
180 lines
4.6 KiB
Markdown
# Professional RDP Client
|
|
|
|
A modern Python-based RDP client with GUI interface that replaces the zenity-based bash script with enhanced functionality and better user experience.
|
|
|
|
## Features
|
|
|
|
- **Professional GUI Interface**: Modern tkinter-based interface with Microsoft RDP Client-like design
|
|
- **Connection Management**: Save, load, and manage multiple RDP connections
|
|
- **Credential Storage**: Encrypted password storage with automatic credential management
|
|
- **Connection History**: Track and quickly access recently used connections
|
|
- **Full Feature Support**:
|
|
- Multiple monitor support
|
|
- Sound and microphone redirection
|
|
- Clipboard sharing
|
|
- Drive sharing
|
|
- Custom resolutions and color depths
|
|
- Various display options (wallpaper, themes, fonts)
|
|
|
|
## Requirements
|
|
|
|
- Python 3.6+
|
|
- xfreerdp (FreeRDP client)
|
|
- Required Python packages:
|
|
- tkinter (usually included with Python)
|
|
- cryptography
|
|
- threading
|
|
- subprocess
|
|
|
|
## Installation
|
|
|
|
1. Clone this repository:
|
|
```bash
|
|
git clone git@gitea.egonetix.de:root/rdp_client.git
|
|
cd rdp_client
|
|
```
|
|
|
|
2. Install dependencies:
|
|
```bash
|
|
# Install FreeRDP
|
|
sudo apt-get install freerdp2-x11 # Ubuntu/Debian
|
|
# or
|
|
sudo dnf install freerdp # Fedora/RHEL
|
|
|
|
# Install Python dependencies
|
|
pip install cryptography
|
|
```
|
|
|
|
3. Make the script executable:
|
|
```bash
|
|
chmod +x rdp_client.py
|
|
```
|
|
|
|
## Usage
|
|
|
|
### Running the Application
|
|
|
|
```bash
|
|
./rdp_client.py
|
|
```
|
|
|
|
Or with Python directly:
|
|
```bash
|
|
python3 rdp_client.py
|
|
```
|
|
|
|
### Virtual Environment Support
|
|
|
|
The script automatically detects and uses a virtual environment if available in the same directory:
|
|
```bash
|
|
python3 -m venv .venv
|
|
source .venv/bin/activate
|
|
pip install cryptography
|
|
./rdp_client.py
|
|
```
|
|
|
|
### Creating Connections
|
|
|
|
1. Click "New Connection" or press Ctrl+N
|
|
2. Fill in the connection details:
|
|
- Server/IP address
|
|
- Username and password
|
|
- Domain (optional)
|
|
- Display settings
|
|
- Feature options
|
|
3. Save the connection for future use
|
|
|
|
### Managing Connections
|
|
|
|
- **Connect**: Double-click a saved connection or select and click "Connect"
|
|
- **Edit**: Right-click a connection and select "Edit"
|
|
- **Delete**: Right-click a connection and select "Delete"
|
|
- **Recent Connections**: Access recently used connections from the history list
|
|
|
|
## Configuration
|
|
|
|
Configuration files are stored in `~/.config/rdp-client/`:
|
|
- `connections.json`: Saved connection profiles
|
|
- `credentials.json`: Encrypted passwords
|
|
- `history.json`: Connection history
|
|
- `rdp_client.log`: Application logs
|
|
|
|
## Security
|
|
|
|
- Passwords are encrypted using Fernet (symmetric encryption)
|
|
- Encryption key is derived from username@hostname
|
|
- Credential files have restricted permissions (600)
|
|
|
|
## Keyboard Shortcuts
|
|
|
|
- **F1**: Show help and shortcuts
|
|
- **Ctrl+N**: New connection
|
|
- **Ctrl+Q**: Quit application
|
|
- **Delete**: Delete selected connection
|
|
- **Enter**: Connect to selected connection
|
|
|
|
## Troubleshooting
|
|
|
|
### Connection Issues
|
|
|
|
1. Verify FreeRDP is installed: `which xfreerdp`
|
|
2. Test manual connection with generated command (shown in logs)
|
|
3. Check server accessibility: `ping your-server`
|
|
4. Verify credentials and domain settings
|
|
|
|
### Common Error Solutions
|
|
|
|
- **STATUS_ACCOUNT_RESTRICTION**: Usually resolved by the built-in security parameter handling
|
|
- **Connection timeout**: Check network connectivity and server availability
|
|
- **Authentication failure**: Verify username, password, and domain
|
|
|
|
### Logs
|
|
|
|
Check the log file for detailed error information:
|
|
```bash
|
|
tail -f ~/.config/rdp-client/rdp_client.log
|
|
```
|
|
|
|
## Migration from Bash Script
|
|
|
|
If migrating from the old zenity-based bash script:
|
|
|
|
1. Connection profiles are compatible and will be automatically detected
|
|
2. Encrypted credentials from the Python version will be used
|
|
3. The bash script's .cred files (if any) need to be recreated in the new interface
|
|
|
|
## Development
|
|
|
|
### File Structure
|
|
|
|
- `rdp_client.py`: Main application file
|
|
- `README.md`: Documentation
|
|
- `.venv/`: Virtual environment (if used)
|
|
|
|
### Contributing
|
|
|
|
1. Fork the repository
|
|
2. Create a feature branch
|
|
3. Make your changes
|
|
4. Test thoroughly
|
|
5. Submit a pull request
|
|
|
|
## License
|
|
|
|
This project is licensed under the MIT License - see the LICENSE file for details.
|
|
|
|
## Author
|
|
|
|
Enhanced RDP Client with Professional GUI
|
|
- Replaces zenity-based bash script with modern Python interface
|
|
- Maintains compatibility with existing connection profiles
|
|
- Adds encrypted credential storage and connection management
|
|
|
|
## Version History
|
|
|
|
- **v2.0**: Complete Python rewrite with GUI interface
|
|
- **v1.0**: Original bash script with zenity interface
|
|
|
|
---
|
|
|
|
**Note**: This client provides the same reliable RDP connectivity as the original bash script but with enhanced user experience and modern interface design. |