An unpatched Cacti zero-day lets an anonymous visitor run commands on the server in four HTTP requests. The flaw affects Cacti Core 1.2.31, the newest release of the open-source network monitoring tool, when guest access is turned on. No CVE number has been assigned, and no fix exists.
A researcher who goes by ek0ms savi0r published the full chain and a working script on GitHub on November 26, 2026. The write-up calls the bug 4HTTP2SHELL. At 20:09 UTC that day, watchTowr released an FAQ under the name 4HTTP2ROOT, listing the vendor patch as pending.
I found a path from a fresh, unauthenticated HTTP session to command execution as the Cacti server user in four requests. No login. No valid API key. No phishing.
— ek0ms savi0r, security researcher, Church of Malware
Cacti 1.2.31 shipped on June 15, 2026, and is still marked as the latest version on the project's GitHub releases page. The researcher reports testing only that build, in an isolated lab running PHP 8.4.27. No source says whether older versions or the development branch are affected.
Every step of the attack goes through the guest session. Cacti's own documentation says the guest user (an account for unauthenticated visitors) has been off by default since version 0.8.7. Once enabled, the default guest can see every graph on the system.
| Request | Endpoint | What happens |
|---|---|---|
| 1 | auth_profile.php?tab=general |
Cacti issues a guest session cookie and a CSRF token without any credentials |
| 2 | auth_profile.php?action=update_data |
The guest saves a string with an extra SQL statement into the preview_graphs_per_page setting |
| 3 | graph_view.php?action=preview |
The stored value lands in a SQL LIMIT clause, and the extra UPDATE writes a shell command into poller_item.arg1 |
| 4 | graph_realtime.php?action=init |
The realtime poller reads arg1 and passes it to PHP's popen(), which runs the command |
The first request is a plain visit. A fresh visitor to auth_profile.php?tab=general&header=false gets a valid Cacti session and a csrfMagicToken value back, with no username or password sent.
The second request abuses a display preference. preview_graphs_per_page should hold a page size, a small whole number. The profile endpoint checks that the setting name exists but never checks that the value is an integer. The researcher stores a value that starts with "1", followed by a stacked UPDATE on the poller_item table carrying a hex-encoded shell command.
Storage itself is safe, because Cacti writes the value into the settings_user table through a prepared statement.
The third request triggers a second-order SQL injection, where malicious data is saved first and executed later by a different part of the code. Loading graph_view.php?action=preview&page=1&clear=1 makes Cacti read the guest's saved page size as the default for its graphs filter. Line 657 of graph_view.php builds the limit from that value. Lines 1574 to 1578 of lib/auth.php paste it into the query as LIMIT $sql_limit inside get_allowed_graphs().
Cacti does filter request parameters with PHP's FILTER_VALIDATE_INT. That filter never sees a default pulled from the database. The PDO database driver accepts several statements in one string, so the injected UPDATE runs after the legitimate SELECT. The browser receives an ordinary preview, and the only trace is a PHP warning about a non-numeric value.
The fourth request turns the database write into a shell. graph_realtime.php?action=init&local_graph_id=1&ds_step=10&size=90 is reachable from the guest session and starts poller_realtime.php, which calls cmd_realtime.php. At line 221 that file hands $item['arg1'] to exec_poll(). Then lib/poller.php (lines 32 to 56) runs it through popen(), with no allowlist of permitted commands. The command executes inside the same HTTP request, which returns a JSON object with a graph image.
The database row the guest can write is the row the poller executes.
— ek0ms savi0r, security researcher, Church of Malware
The lab log from November 24 adds that the realtime endpoint showed "no login redirect, no permission-denied page, no realm check." That injection channel also let the researcher read values from the database through a modified user_auth record. A final DELETE on settings_user removed the planted preview_graphs_per_page row afterward.
Root access is a lab artifact. The README title promises "Four Requests to Root." Its 39-byte proof file showed uid=0(root), because the researcher's web server and poller ran as root. Cacti afterward served that file back over HTTP from its own webroot. On a typical install the commands run as the Cacti web user, usually www-data or apache. watchTowr agrees and describes the gained account as "often a low privileged web user rather than root."
Even a low-privileged shell on a Cacti host reaches valuable material. The researcher lists SNMP community strings, device logins stored in the database, and SSH keys or service accounts used by pollers. Database credentials sit in include/config.php. The same host keeps mail relay credentials, cron jobs and backup scripts, and access to internal management networks.
Stolen logins are only part of the payoff. With a shell on the monitoring host, the researcher writes, an attacker can change the data the operations team sees. Editing the poller or the database lets the intruder suppress alerts. The host can then serve as a pivot into network segments that only the monitoring server can reach.
Because Cacti often stores credentials and connection details for routers, switches, servers, and other devices across a network, an attacker who reaches this level of command execution can gain a foothold reaching far beyond the monitoring server itself.
— watchTowr, 4HTTP2ROOT FAQ, November 26, 2026
The researcher points out that each of the four requests looks like routine traffic. The chain needs no file upload and creates no login event. Its loudest trace is the non-numeric value warning, and the write-up notes that most teams do not alert on it.
auth_profile.php, the file behind the first two requests, already received a security fix in June. Cacti 1.2.31 closed CVE-2026-39900, a reflected XSS (cross-site scripting) through its tab parameter. The same release fixed CVE-2026-46531, a SQL injection in automation_tree_rules.php. The page-size bug survived that update.
As of November 27, watchTowr reports no exploitation in the wild. The bug is not in the CISA Known Exploited Vulnerabilities catalog, and watchTowr's CVSS field shows 0.0, with no real score assigned. Commits to Cacti's develop branch on November 26 and 27 cover translations, i18n fixes, CI scanning rules and a contributor list update, with no change to preview_graphs_per_page. The project's issue tracker has no public report about the bug, and the README does not say whether the developers were told before publication.
Public script, no fixed release
Working exploit code for the chain is public on GitHub, and Cacti has not shipped a fixed version. Any Cacti 1.2.31 server with the guest account enabled faces the most direct risk, especially when its web interface is reachable from untrusted networks, according to watchTowr.
watchTowr's advice is to disable the guest account in Cacti's user management settings, which removes the entry point. The company recommends keeping the web interface on trusted internal networks until an official patch appears. Signs that the chain already ran include unexpected commands in poller_item entries and new files created by the poller process. watchTowr also advises searching Cacti logs for non-numeric value warnings tied to graph display settings and installing the vendor's fix once it ships.
Have a story? Become a contributor.
We work with independent researchers and cybersecurity professionals. Send us a tip or submit your article for editorial review.