{"id":"MSF-multi--http--cpanel_whm_auth_bypass_rce","name":"cPanel/WHM CRLF Injection Authentication Bypass RCE","description":"Exploits CVE-2026-41940, a CRLF injection in cPanel/WHM's cpsrvd daemon that allows unauthenticated remote code execution as root. The Basic-auth handler writes the password to the raw session file without stripping newlines. Omitting the ob-part of the session cookie bypasses the encoder, so injected fields land verbatim in the raw file. A subsequent request to /scripts2/listaccts triggers Cpanel::Session::Modify to promote those fields into the authoritative session cache, granting root WHM access. RCE uses the WHM JSON API passwd endpoint to set a temporary root password, then delivers the payload over SSH. The password is rotated after exploitation. This module does not restore the original root password. Affects all versions after 11.40. Fixed per branch: 11.86.0.41, 11.110.0.97, 11.118.0.63, 11.124.0.35, 11.126.0.54, 11.130.0.19, 11.132.0.29, 11.134.0.20, 11.136.0.5 (cPanel/WHM) and 136.1.7 (WP2).","cves":["CVE-2026-41940"],"author":"Sina Kheirkhah, Adam Kues, Shubham Shah, Crypto-Cat","published":"2026-04-28","platform":"Unix","type":"remote","language":"Ruby","source":"metasploit","sourceUrl":"https://github.com/rapid7/metasploit-framework/blob/90dfbaa741421d0179f9f371109c215d49400444/modules/exploits/multi/http/cpanel_whm_auth_bypass_rce.rb","path":"modules/exploits/multi/http/cpanel_whm_auth_bypass_rce.rb","revision":"90dfbaa741421d0179f9f371109c215d49400444","filename":"cpanel_whm_auth_bypass_rce.rb","vulnerabilities":[{"id":"CVE-2026-41940","state":"PUBLISHED","title":"WebPros cPanel and WHM Authentication Bypass via Login Flow","titleSource":"CVE Program","description":"cPanel and WHM versions after 11.40 contain an authentication bypass vulnerability in the login flow that allows unauthenticated remote attackers to gain unauthorized access to the control panel.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2026-41940","cvss":{"version":"4.0","baseScore":9.3,"severity":"critical","vectorString":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","source":"VulnCheck","sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-41940"},"updatedAt":"2026-09-30T17:20:17.713Z","retrievedAt":"2026-11-25T16:15:50.291Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/MSF-multi--http--cpanel_whm_auth_bypass_rce.png?v=2","url":"https://exploitbin.com/exploits/MSF-multi--http--cpanel_whm_auth_bypass_rce","downloadUrl":"https://exploitbin.com/api/v1/exploits/MSF-multi--http--cpanel_whm_auth_bypass_rce/download","codeUrl":"https://exploitbin.com/api/v1/exploits/MSF-multi--http--cpanel_whm_auth_bypass_rce/code","licenseUrl":"https://exploitbin.com/sources#metasploit"}