Improper regex in htaccess file
Description
ImpactThe default .htaccess file has some restrictions in the access to PHP files to only allow specific PHP files to be executed in the root of the application.
This logic isn't correct, as the regex in the second FilesMatch only checks the filename, not the full path.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Mautic's default .htaccess has an incorrect regex that only checks the filename, allowing unauthorized PHP files to be executed in the root.
Root
Cause CVE-2022-25769 affects Mautic, an open-source marketing automation platform. The vulnerability lies in the default .htaccess file, which is intended to restrict execution of PHP files in the application's root directory to only a specific set of allowed files. However, the regex used in the second FilesMatch directive only checks the filename component of the request, not the full path. This oversight means that requests containing directory traversal or other path manipulation can bypass the intended restriction [1].
Exploitation
An attacker can exploit this by crafting a request that, for example, includes a path segment that resolves to a disallowed PHP file but whose filename matches the allowed regex pattern. Since the regex only inspects the filename, such a request would not be blocked. The attack requires no authentication and can be performed over the network, as the .htaccess rules are evaluated before any application-level authentication [1].
Impact
Successful exploitation allows an attacker to execute arbitrary PHP files in the root directory of the Mautic application that should not be directly accessible. This could lead to information disclosure, code execution, or further compromise of the application and its underlying server, depending on the capabilities of the executed PHP file [1].
Mitigation
The vulnerability is fixed in Mautic versions 3.3.5 and 4.2.0. Users should upgrade to these versions or later. No workaround is available for earlier releases. The issue is tracked internally as MST-32 [1].
AI Insight generated on May 20, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
mautic/corePackagist | < 3.3.5 | 3.3.5 |
mautic/corePackagist | >= 4.0.0, < 4.2.0 | 4.2.0 |
Affected products
2- Mautic/Mauticv5Range: < 3.3.5
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
3News mentions
0No linked articles in our index yet.