Skip to content

auser/pythonic-vnc-control

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fedwire VNC Automation Client

This project provides an automated client for interacting with a remote Windows desktop over VNC, specifically designed for automating workflows such as launching applications, taking screenshots, and managing windows. It is intended for use cases like Fedwire or other secure desktop environments where automation and remote control are required.

Purpose

  • Automate remote desktop workflows via VNC (Virtual Network Computing)
  • Open applications (e.g., Chrome) using the Start menu
  • Take screenshots at various stages for auditing or monitoring
  • Close all open windows programmatically
  • Integrate with secure environments (e.g., Fedwire, banking terminals)

Features

  • Connects to a remote Windows machine using VNC credentials
  • Automates GUI actions: open Start menu, launch apps, close windows
  • Takes screenshots and saves them locally for each step
  • CLI interface with adjustable logging verbosity
  • Easily extensible for more automation tasks

Setup

1. Clone the repository

git clone <repo-url>
cd <repo-directory>

2. Install dependencies (with uv)

This project uses uv for fast and reliable Python dependency management:

uv venv

This will install all dependencies specified in pyproject.toml.

If you need to add a new dependency:

uv add <package-name>

3. Configure environment variables

Create a .env file or set environment variables as needed. The project uses a config file (see fedwire/config.py) to load VNC and remote credentials. Example:

VNC_HOST=10.10.8.8
VNC_PORT=1507
VNC_USERNAME=username
VNC_PASSWORD=password

Or edit your config file as appropriate.

Usage

Command Line Interface

Run the main script with:

uv run main.py [OPTIONS]

Options

  • -v, --verbose : Increase logging verbosity. Can be repeated:
    • No -v: WARNING
    • -v: INFO
    • -vv: DEBUG
    • -vvv: NOTSET (all logs)

Example

uv run main.py -vv

What it does

  1. Connects to the remote VNC server using credentials from config
  2. Cleans up old screenshots
  3. Takes an initial screenshot (initial-screen.png)
  4. Opens the Start menu and launches Chrome
  5. Takes a screenshot after Chrome is opened (start-menu-opened.png)
  6. Closes all open windows (sends Alt+F4 multiple times)
  7. Takes a final screenshot (completed.png)

Screenshots are saved in the screenshots/ directory.

Extending

  • Add new automation steps in fedwire/actions/
  • Update the workflow in main.py as needed
  • Use the asyncvnc client to send keyboard/mouse events, automate login, etc.

Troubleshooting

  • Connection errors: Ensure the VNC server is running and credentials are correct
  • Too many attempts: The VNC server may temporarily block you after repeated failed logins
  • Windows not closing: Some windows may require additional confirmation or may be protected from Alt+F4

License

MIT or as specified in the repository

Authors


For more details, see the code in main.py and fedwire/actions/.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages