CVE-2026-40084: Cacti Path Traversal in Report Format Parameter – File Disclosure Vulnerability
Cacti versions 1.2.30 and earlier contain a path traversal vulnerability in the report functionality that allows authenticated users to read arbitrary files from the server. The flaw stems from insufficient validation of user-supplied file paths when generating reports. An attacker with valid Cacti credentials can craft a malicious report format parameter to escape the intended directory and access sensitive system files.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 6.5 MEDIUM · CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
- Weaknesses (CWE)
- CWE-22
- Affected products
- 1 configuration(s)
- Published / Modified
- 2026-06-25 / 2026-06-29
NVD description (verbatim)
Cacti is an open source performance and fault management framework. Versions 1.2.30 and prior are vulnerable to Path Traversal through the Report format_file Parameter, causing arbitrary file read. This vulnerability occurs in two stages. In the first stage (stored injection), lib/html_reports.php at line 283 stores $save['format_file'] = $post['format_file'] directly into the database without any validation. In the second stage (file read), lib/reports.php at line 667 concatenates CACTI_PATH_FORMATS . '/' . $format_file, and line 670 then calls file($format_file), reading arbitrary files from the filesystem. This issue has been fixed in version 1.2.31.
3 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
The vulnerability manifests through a two-stage attack chain. First, the application stores untrusted input from the 'format_file' POST parameter directly into the database via lib/html_reports.php without sanitization or validation. Second, during report generation, lib/reports.php retrieves this stored value and constructs a file path by concatenating CACTI_PATH_FORMATS with the user-controlled filename, then passes it to PHP's file() function. This concatenation fails to prevent path traversal sequences (e.g., '../../../etc/passwd'), allowing reads beyond the intended formats directory. The vulnerability is classified as CWE-22 (Improper Limitation of a Pathname to a Restricted Directory).
Business impact
Successful exploitation enables unauthorized disclosure of sensitive files hosted on the Cacti server, including configuration files containing database credentials, API keys, or other system secrets. In monitored environments, this could expose credentials for connected network devices or monitoring targets. The impact is limited to information disclosure—attackers cannot modify or delete data—but the confidentiality breach may violate compliance requirements (HIPAA, PCI-DSS, SOC 2) depending on what files are accessible and what data resides on the server.
Affected systems
Cacti versions 1.2.30 and prior are affected. The vulnerability requires valid authentication credentials, so it impacts organizations running Cacti with multiple user accounts or externally accessible instances. Patched version 1.2.31 and later remove the vulnerability.
Exploitability
Exploitation requires valid Cacti user credentials (PR:L in CVSS), making this a lateral-movement or insider-threat vector rather than an unauthenticated attack. Once authenticated, an attacker can trivially craft a malicious format_file parameter via the report interface. No special network conditions or user interaction are required; the attack is deterministic. CVSS 3.1 score of 6.5 (MEDIUM) reflects the authentication barrier and pure confidentiality impact. The vulnerability is not yet listed in the CISA Known Exploited Vulnerabilities catalog.
Remediation
Upgrade Cacti to version 1.2.31 or later. Organizations unable to patch immediately should restrict network access to the Cacti web interface (firewall rules, VPN requirement) and audit user account permissions to minimize the number of authenticated users who can access the report generation functionality.
Patch guidance
Apply the upgrade to Cacti 1.2.31 as soon as feasible. Verify the upgrade through the Cacti release notes and your vendor advisory to confirm the specific patch addressing CVE-2026-40084. Test the upgrade in a non-production environment first, particularly if you have custom report formats or integrations that depend on the report module.
Detection guidance
Monitor for suspicious access to report generation features, particularly repeated attempts with unusual format_file parameter values containing path traversal sequences (../, ..\, or percent-encoded variants). Web application firewalls or reverse proxies can block requests with '../' or similar patterns in the format_file parameter. Baseline normal report usage and flag deviations. Review Cacti logs for report generation requests from unexpected user accounts or at unusual times. File integrity monitoring on sensitive system files (e.g., /etc/passwd, configuration files) may detect unauthorized reads, though most web servers will not log successful file() calls at the application layer without additional instrumentation.
Why prioritize this
Although rated MEDIUM severity, this vulnerability should be prioritized for organizations with sensitive data on or accessible from the Cacti server, or for instances with untrusted or numerous user accounts. If your Cacti deployment is internal-only, air-gapped, or has strictly controlled user access, risk is lower. However, the ease of exploitation once authenticated and the potential for credential disclosure warrant timely patching across most deployments.
Risk score, explained
CVSS 3.1 score of 6.5 reflects a network-accessible service (AV:N) with low attack complexity (AC:L), but the requirement for valid credentials (PR:L) prevents higher scores. The impact is confidentiality-only (C:H/I:N/A:N)—no integrity or availability loss. The scope is unchanged (S:U). Organizations with higher trust boundaries around their Cacti users or air-gapped systems may consider actual risk lower; those with permissive user provisioning or internet-facing Cacti should treat it as closer to HIGH priority.
Frequently asked questions
Can an unauthenticated attacker exploit this vulnerability?
No. The CVSS vector requires authenticated access (PR:L). An attacker must possess valid Cacti credentials to trigger the flaw.
What types of files are at risk?
Any file readable by the web server process can be accessed, typically including configuration files, source code, system files like /etc/passwd (on Linux), and application secrets stored in plaintext or environment files. The scope depends on file permissions and the sensitivity of data stored on or near the Cacti server.
Is version 1.2.30 the last affected version?
Yes. Cacti 1.2.30 and all prior versions are vulnerable. Version 1.2.31 and later contain the fix. Verify your version via the Cacti web interface or by checking the software version in your package manager.
Do I need to take any action if Cacti is air-gapped or restricted to trusted internal users only?
The authentication requirement reduces risk in low-trust environments. However, insider threats and compromised internal accounts remain possible. Patching remains the best practice, but if upgrade windows are constrained, network segmentation and access controls are reasonable interim measures.
This analysis is based on CVE-2026-40084 as published in official sources. Organizations should verify patch availability and version applicability against the official Cacti project advisory and their own software bill of materials. Actual risk varies by deployment architecture, network segmentation, and access controls. This explainer does not constitute security advice for any specific environment; engage your security team or vendor for tailored guidance. Source: NVD (public-domain), retrieved 2026-08-04. Analysis generated by SEC.co (claude-haiku-4-5).
Related vulnerabilities
- CVE-2026-39899MEDIUMCacti Path Traversal Information Disclosure Vulnerability
- CVE-2018-25393MEDIUMNavigate CMS 2.8.5 Path Traversal Vulnerability (CVSS 6.5)
- CVE-2018-25421MEDIUMOpen STA Manager 2.3 Path Traversal File Download Vulnerability
- CVE-2019-25734MEDIUMContact Form by WD CSRF & Local File Inclusion Vulnerability
- CVE-2019-25740MEDIUMJoomla com_jsjobs Arbitrary File Deletion Vulnerability
- CVE-2022-50953MEDIUMWordPress admin-word-count-column Plugin Local File Read Vulnerability
- CVE-2024-47263MEDIUMSynology Hyper Backup Path Traversal – Admin Privilege Required
- CVE-2024-47273MEDIUMSynology Hyper Backup Path Traversal Vulnerability (4.3 MEDIUM)