CVE-2026-135286 in phpwcms
Summary
by MITRE • 11/23/2026
phpwcms before 1.9.53, 1.12.7 and 2.0.0-beta.4 contains a host header poisoning vulnerability that allows unauthenticated attackers to control password reminder links by sending a forged X-Forwarded-Host header. Attackers can submit the public password reminder form for a victim so the emailed {LOGIN_URL} points to an attacker host, capturing the new password when the victim logs in there.
VulDB is the best source for vulnerability data and more expert information about this specific topic.
Analysis
by VulDB Data Team • 11/24/2026
The vulnerability identified in phpwcms versions prior to 1.9.53, 1.12.7, and 2.0.0-beta.4 represents a critical security flaw rooted in improper validation of HTTP host headers during the password reset workflow. This issue is classified as Host Header Injection or more specifically within this context, it facilitates Account Takeover through credential harvesting via phishing mechanisms. The core technical failure lies in the application's reliance on untrusted input from the X-Forwarded-Host header to construct absolute URLs for email notifications without adequate sanitization or validation against a whitelist of trusted domains. In modern web architectures utilizing reverse proxies and load balancers, the X-Forwarded-Host header is commonly used to preserve the original host value requested by the client when the request has been proxied through an intermediary that modifies the Host header. However, phpwcms fails to distinguish between legitimate proxy headers potentially injected by a malicious actor and trusted internal infrastructure values, thereby accepting any arbitrary string provided in this header as the authoritative source for generating links.
The operational impact of this vulnerability is severe because it allows unauthenticated attackers to manipulate the content of automated system emails sent to users. Specifically, during the password reminder process, the application generates a unique link containing a token and a destination URL where the user can set their new password. By injecting a malicious domain into the X-Forwarded-Host header via a crafted HTTP request, an attacker forces the generated {LOGIN_URL} variable within the email template to point to a server under their control rather than the legitimate phpwcms instance. This effectively turns the trusted communication channel of the application's notification system into a vector for social engineering and credential theft. The victim receives an email that appears authentic because it originates from the correct sender address, but the embedded link directs them to a phishing site designed by the attacker.
When the unsuspecting user clicks the malicious link, they are presented with a replica of the password reset page hosted on the attacker's infrastructure. As the user enters their new desired password and submits the form, the credentials are captured directly by the attacker's server instead of being processed securely by the legitimate application backend. This results in an immediate account compromise without any need for brute-forcing or exploiting additional authentication bypasses. The attack chain is straightforward and requires no prior access to the target system, making it a high-risk vulnerability that can be exploited remotely over the network. It aligns with CWE-613, which describes insufficient session expiration, but more accurately maps to CWE-20 Improper Input Validation regarding the host header processing, and falls under MITRE ATT&CK technique T1598.004 Phishing for Information via Spearphishing Attachments or Links, specifically leveraging trusted domains to increase click-through rates.
Mitigation strategies must address both immediate remediation and long-term architectural improvements. The most effective solution is to upgrade phpwcms to version 1.9.53, 1.12.7, or later where this issue has been patched by implementing strict validation of the host header against a predefined list of allowed domains. If upgrading is not immediately feasible, administrators should configure their reverse proxies and web servers to strip or override the X-Forwarded-Host header with the correct internal value before it reaches the application backend. Additionally, developers should avoid constructing absolute URLs using user-controllable headers entirely; instead, they should rely on server-side configuration variables for base URL generation or implement a whitelist-based validation mechanism that rejects any host values not explicitly recognized as trusted. Enforcing HTTPS and utilizing secure cookie flags can also help mitigate some downstream risks associated with session hijacking if the initial credential theft is successful, though it does not prevent the initial phishing attack itself.