Skip to main content

exec-across-windows

A tool for executing commands across multiple Windows systems using various remote execution methods. Automatically tries multiple techniques until one succeeds, based on return codes and output. Makes executing commands given credentials a hell of a lot easier.

Big thanks to NetExec, Impacket, and Evil-Winrm, as this tool just essentially acts as a wrapper around those (making it more of a script, I suppose).

Features

  • Multiple RCE Methods: Automatically tries various Windows remote execution techniques:
    • WinRM (HTTP/HTTPS)
    • PSExec (Impacket)
    • SMBExec (NetExec)
    • WMI (NetExec)
    • AtExec (Impacket)
    • RDP (NetExec)
    • SSH (NetExec)
    • MSSQL (Impacket)
  • Multi-threaded: Execute commands across multiple hosts simultaneously
  • Automatic Pass-the-Hash: Just paste the NTLM hash as the credential

Installation

pipx install exec-across-windows

External Dependencies

This tool requires the following external tools to be installed:

# Impacket (for PSExec, AtExec, MSSQL)
pipx install impacket

# NetExec (for SMBExec, WMI, RDP, SSH)
pipx install git+https://github.com/Pennyw0rth/NetExec

# Evil-WinRM (for WinRM)
gem install evil-winrm

Usage

Basic Usage

# Execute command on single host
exec-across-windows 192.168.1.10 administrator Password123 whoami

# Execute across IP range of 192.168.1.1 to 192.168.1.50
exec-across-windows 192.168.1.1-50 admin Pass123 "net user"

# Use hash instead of password
exec-across-windows 10.0.0.1-10 admin :{32-bit-hash} whoami

IP Range Format

Supports various formats:

  • Single IP: 192.168.1.10
  • Range: 192.168.1.1-254
  • Multiple ranges: 10.0.1-5.10-20 (expands to all combinations)
  • File with IP ranges: targets.txt

Credential File Format

Create a text file with alternating username/password lines:

administrator
Password123!
admin
Pass123
backup_admin
:aad3b435b51404eeaad3b435b51404ee

Lines starting with # are treated as comments. For NT hashes, use them directly as the password.

Command-Line Options

Options:
  -v                      Verbose output (shows all tool attempts)
  -o                      Show successful command output (WARNING: may trigger AV)
  -f <file>               Use credential file instead of single username/password
  --threads <n>           Number of concurrent threads (default: 10)
  --tools <list>          Comma-separated list of tools to try in order
  --timeout <seconds>     Command timeout in seconds (default: 15)
  --run-all               Run all tools instead of stopping at first success
  --skip-portscan         Skip port scanning and attempt all tools

Todo

Add kerberos support lol

  • Requires supporting hostnames and configuring /etc/krb5.conf for tools like evil-winrm

License

MIT License - see LICENSE file for details

Disclaimer

This tool is intended for authorized security assessments only. Ensure you have proper authorization before using this tool on any systems you do not own or have explicit permission to test.

Metadata

Release files for exec-across-windows 1.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for exec-across-windows 1.0.4
File Size Uploaded
exec_across_windows-1.0.4.tar.gz 11.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for exec-across-windows 1.0.4
File Interpreter ABI Platform
exec_across_windows-1.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 21.8 kB

Release files / exec_across_windows-1.0.4.tar.gz

Download URL exec_across_windows-1.0.4.tar.gz
Size 11.3 kB
Tags Source
SHA-256 checksum
How to use checksums
86d9c378e9b877afabad7290f45fbe9b3704bd13e2c0947e511778c28e2cb95e
BLAKE2b-256 checksum
How to use checksums
4a72a417e4d0f7b07bbedbf9edb229b7e54c8cd3be688b7edef882bf0f87360e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Release files / exec_across_windows-1.0.4-py3-none-any.whl

Download URL exec_across_windows-1.0.4-py3-none-any.whl
Size 10.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
09198a98c5294764a200e1dac599fe532301d6047d0d4ce83a4232f41e7cb766
BLAKE2b-256 checksum
How to use checksums
e7cfa3520e0b1fe7366137bef0e1f0ec250f9ef6b4dcd01241b85cd688268f47
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Release history Release notifications | RSS feed

This release

1.0.4 This release

2 release files

1.0.3

2 release files

1.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page