
होस्ट्स में CVE-2021-41773 भेद्यता की जाँच के लिए प्रमाण-अवधारणा।
Apache HTTP Server 2.4.49-2.4.50 में पथ सामान्यीकरण में किए गए परिवर्तन में एक दोष पाया गया।
एक हमलावर पथ ट्रैवर्सल हमले का उपयोग करके URL को अपेक्षित दस्तावेज़ रूट के बाहर की फ़ाइलों से मैप कर सकता है। यदि दस्तावेज़ रूट के बाहर की फ़ाइलें "require all denied" द्वारा सुरक्षित नहीं हैं, तो ये अनुरोध सफल हो सकते हैं। इसके अतिरिक्त, यह दोष CGI स्क्रिप्ट्स जैसी व्याख्या की गई फ़ाइलों का स्रोत लीक कर सकता है।
यह समस्या केवल Apache 2.4.49 और 2.4.50 को प्रभावित करती है, पुराने संस्करणों को नहीं।
वर्तमान में दो तरीके हैं:
/etc/apache2/apache2.conf में निम्नलिखित संपादित करें:<!-- Vulnerable (Require all granted in '/') -->
<Directory />
Options FollowSymLinks
AllowOverride None
Require all granted
</Directory>
<!-- Patched (Require all denied in '/') -->
<Directory />
Options FollowSymLinks
AllowOverride None
Require all denied
</Directory>
स्क्रिप्ट का उपयोग इस प्रकार करें:
CVE-2021-41773.py [-h] [--nosslcheck] [--cores CORES] [--file TARGETFILE] host
Checks if an apache server is vulnerable to CVE-2021-41773.
optional arguments:
-h, --help show this help message and exit
--host HOST ip/domain to be checked e.g. 'https://google.com/'.
--nosslcheck, -n Do not verify ssl certificates.
--cores CORES, -C CORES
Specify number of cores that should be dedicated to the task, default: 1
--file TARGETFILE, -f TARGETFILE
Specify file to fetch list of hosts from, example: "/home/user/Desktop/myfile.txt"
--rce, -r When toggled checks if target is susceptible to RCE (NOT YET IMPLEMENTED!)