Skip to main content

A Tool for automating the MITM attack on the WSUS connection

Project description

Supported Python versions Twitter

wsuks

Weaponizing the WSUS Attack

Gaining local administrative access on a Windows machine that is part of a domain is typically the initial step towards acquiring domain admin privileges during a penetration test. In order to exploit the WSUS attack automatically, this tool spoofs the IP address of the WSUS server within the network using ARP, and when the client requests Windows updates, it provides its own malicious updates instead. By default, a Windows client requests updates every 24 hours.

Both the executable file served (Default: PsExec64.exe) and the executed command can be changed as needed.

Prerequisits:

  • The target Client must be on the local network
  • The Windows Server Update Service (WSUS) must be configured using HTTP

Result:

  • After successful execution a user with the format user[0-9]{5} (e.g. user12345) and a random password will be created and added to the local admin group

Installation

Using pipx:

sudo apt install python3-pipx
pipx ensurepath
pipx install wsuks
sudo ln -s ~/.local/pipx/venvs/wsuks/bin/wsuks /usr/local/bin/wsuks

Using poetry:

sudo apt install python3-poetry
git clone https://github.com/NeffIsBack/wsuks
cd wsuks
sudo poetry install

Usage

❗wsuks must be run as root❗

With pipx:

sudo wsuks
suso wsuks -t 10.0.0.10 --WSUS-Server 10.0.0.20

With poetry:

sudo poetry run wsuks
sudo poetry run wsuks -t 10.0.0.10 --WSUS-Server 10.0.0.20

About & Mitigation

In the PyWSUS Repository from GoSecure you can find a great documentation how to you could detect and mitigate this attack. They also wrote a great Guide demonstrating how this attack works in detail here.

This Tool is based on the following projects:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wsuks-0.3.1.tar.gz (761.6 kB view details)

Uploaded Source

Built Distribution

wsuks-0.3.1-py3-none-any.whl (768.7 kB view details)

Uploaded Python 3

File details

Details for the file wsuks-0.3.1.tar.gz.

File metadata

  • Download URL: wsuks-0.3.1.tar.gz
  • Upload date:
  • Size: 761.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.2 CPython/3.11.4 Linux/6.1.0-kali9-amd64

File hashes

Hashes for wsuks-0.3.1.tar.gz
Algorithm Hash digest
SHA256 7f40689fd5c4029e122c7b64d6cc4c0beb7a81a542dbf10605a9c912bfc60471
MD5 cea3536c935b1462d9a62c91dfcfa85e
BLAKE2b-256 848f25cc4726b70d1e45d1c3a341736950ee15ba5d3fdcc82550c81fdae9808a

See more details on using hashes here.

File details

Details for the file wsuks-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: wsuks-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 768.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.2 CPython/3.11.4 Linux/6.1.0-kali9-amd64

File hashes

Hashes for wsuks-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 bc0263e6c24495ea95b74cc7e245cdf88cc718861d7b9053ba216e9bea7558e0
MD5 e0c1ed9d59d61ead31d9f5f68603fa9f
BLAKE2b-256 f45382006a5b3236d554143614447fceddb9e3c45442484694e3d11d4e51d556

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page