Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
cPanel-WHM-CVE-2026-41940-AuthBypass — Scanner for cPanel & WHM authentication bypass (CVE-2026-41940) that detects vulnerable versions via CRLF injection and session manipulation, with multi-threading and proxy support. | Kitploit
Tools/GitHubGitHub/isee857/cpanel-whm-cve-2026-41940-authbypass
Vulnerability ScannersExploitationWeb Application ExploitationWeb SecurityPenetration TestingAuthenticationRed Teaming
GitHubisee857/cpanel-whm-cve-2026-41940-authbypass

cPanel-WHM-CVE-2026-41940-AuthBypass

Scanner for cPanel & WHM authentication bypass (CVE-2026-41940) that detects vulnerable versions via CRLF injection and session manipulation, with multi-threading and proxy support.

View Repository
34 months agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

CVE-2026-41940 cPanel & WHM Authentication Bypass Scanner

⚠️ Legal Disclaimer

This tool is intended for authorized security testing and educational purposes only. Users must comply with local laws and regulations; scanning unauthorized systems is strictly prohibited. The author is not responsible for any misuse.


🔥 Vulnerability Overview

ItemDetails
CVE IDCVE-2026-41940
Vulnerability NamecPanel & WHM Session File CRLF Injection
Severity🔴 CRITICAL (CVSS 9.8)
Affected VersionscPanel & WHM < 11.110.0.97 / 11.118.0.63 / 11.126.0.54 / 11.132.0.29 / 11.134.0.20 / 11.136.0.5
Vulnerability TypeAuthentication Bypass → Root Privilege Escalation
Exploit DifficultyLow

Vulnerability Details

cPanel & WHM has a logic flaw when handling session files:

  1. The saveSession() function calls filter_sessiondata() only after writing the session file
  2. An attacker can craft an Authorization: Basic header containing CRLF injection
  3. The malicious payload is written directly to the on-disk session file, injecting fields such as hasroot=1, tfa_verified=1
  4. This ultimately bypasses WHM authentication and grants root-level access

✨ Features

✅ Precise Detection - Strictly reproduces the original exploit chain
✅ No Dependencies - Uses only the Python standard library
✅ Multi-threaded - Supports batch scanning
✅ Proxy Support - Compatible with Burp Suite/Owasp ZAP
✅ Smart Parsing - Automatically completes protocol and port
✅ Highlighted Output - Vulnerable results shown in prominent red

Detection Flow (4 Stages)

root@kitploit:~
[1] POST /login/?login_only=1          → Obtain pre-authentication session
[2] GET / + CRLF injection             → Poison the session file
[3] GET /scripts2/listaccts           → Trigger cache refresh
[4] GET /cpsess/token/json-api/version → Verify root privileges

🚀 Quick Start

Requirements

  • Python 3.6+

Download the Script

root@kitploit:~
wget https://github.com/iSee857/cPanel-WHM-CVE-2026-41940-AuthBypass/blob/main/cPanel-WHM-CVE-2026-41940-AuthBypass.py
chmod +x cPanel-WHM-CVE-2026-41940-AuthBypass.py

📖 Usage

Single Target Scan

root@kitploit:~
# Auto-completes https://
python3 cPanel-WHM-CVE-2026-41940-AuthBypass.py -u 1.2.3.4:2087

# Specify full URL
python3 cPanel-WHM-CVE-2026-41940-AuthBypass.py -u https://example.com:2087

Batch Scan

root@kitploit:~
# Read targets from file
python3 cPanel-WHM-CVE-2026-41940-AuthBypass.py -f targets.txt -t 20

# targets.txt format:
# 1.2.3.4:2087
# example.com:2087
# https://test.com:2087

Proxy Scan (with Burp Suite)

root@kitploit:~
# Use HTTP proxy
python3 cPanel-WHM-CVE-2026-41940-AuthBypass.py -u 1.2.3.4:2087 --proxy http://127.0.0.1:8080

# Batch scan through proxy
python3 cPanel-WHM-CVE-2026-41940-AuthBypass.py -f targets.txt --proxy http://127.0.0.1:8080 -t 5

Common Parameters

ParameterDescriptionExample
-u, --urlSingle target-u 1.2.3.4:2087
-f, --fileTarget list file-f targets.txt
-t, --threadsNumber of threads (default 10)-t 20
--timeoutTimeout in seconds (default 10)--timeout 15
--proxyHTTP/HTTPS proxy--proxy http://127.0.0.1:8080

📊 Output Examples

Vulnerability Present (Red Highlight)

root@kitploit:~
13:45:01 [SCAN] Testing 1.2.3.4:2087
13:45:02 [INFO] Got session: 9f3a2c1b8d...
13:45:02 [INFO] Got token: /cpsess1234567890
13:45:03 [VULN] CVE-2026-41940 CONFIRMED! 1.2.3.4:2087
ScreenShot_2025-12-19_151413_652

Vulnerability Not Present

root@kitploit:~
13:46:01 [SCAN] Testing 5.6.7.8:2087
13:46:02 [ERR ] Failed to get session 5.6.7.8:2087

🔍 Vulnerability Verification Notes

The script confirms the vulnerability using the following logic:

  1. Session Acquisition: Successfully obtains the whostmgrsession Cookie
  2. Token Extraction: The response contains a /cpsess{digit} path
  3. Privilege Verification: Accessing /json-api/version returns 200 and includes the "version" field

⚠️ Note: Some targets may return 500/503 with a "License" message; this still indicates a successful authentication bypass, just missing a commercial license.


🛡️ Remediation Recommendations

Upgrade immediately to the following secure versions:

  • 11.110.0.97+
  • 11.118.0.63+
  • 11.126.0.54+
  • 11.132.0.29+
  • 11.134.0.20+
  • 11.136.0.5+

Temporary Mitigation Measures:

  1. Restrict access to the WHM port (2087) by IP
  2. Enable firewall rules
  3. Monitor the /var/cpanel/sessions/ directory for unusual changes

🙏 References & Credits

https://labs.watchtowr.com/the-internet-is-falling-down-falling-down-falling-down-cpanel-whm-authentication-bypass-cve-2026-41940/


⚠️ Final Reminder

This tool is intended solely for authorized security testing and defensive research. Any unauthorized scanning activity is illegal and done at your own risk.


Star ⭐ this project to get more security tool updates!

Download Tool