Mar 1, 2026·5 min read·32 visits
CVE-2026-28425 allows authenticated Statamic users to execute arbitrary code via malicious Antlers template syntax. The flaw exists because the template engine previously failed to distinguish between trusted developer code and untrusted user input, exposing sensitive PHP functions and configuration data. Patches are available in versions 5.73.11 and 6.4.0.
A critical Remote Code Execution (RCE) vulnerability has been identified in the Antlers template engine of Statamic CMS. The vulnerability arises from improper isolation of user-supplied content during template rendering, allowing authenticated users with low privileges to execute arbitrary PHP code. This flaw affects the Control Panel's handling of specific fields and configuration settings, effectively bridging the gap between content editing and server-side execution.
Statamic is a popular CMS built on top of the Laravel framework, utilizing a custom templating language known as 'Antlers'. The engine is designed to be expressive and powerful, allowing developers to manipulate data directly within views. However, this power becomes a liability when the engine processes untrusted input without adequate sandboxing.
The vulnerability, tracked as CVE-2026-28425, resides in how the Statamic Control Panel (CP) handles user-editable fields that have Antlers parsing enabled. In affected versions, the parsing logic does not differentiate between a developer-defined template file and content entered by a CMS user (e.g., in a Bard field, Textarea, or Form configuration). Consequently, the parser grants user input access to the full application context.
This exposure allows an attacker to inject specific Antlers tags that invoke PHP classes, access the Laravel service container, or read environment variables. Because Statamic is often used in environments where content editors are trusted to write text but not code, this privilege escalation from 'content editor' to 'system administrator' represents a critical security breach.
The root cause of this vulnerability is an Improper Control of Generation of Code (CWE-94) within the Statamic\View\Antlers\Parser class. Specifically, the parser failed to implement a 'user-content' mode that restricts the available execution context.
When Statamic parses a template, it hydrates a context array containing variable data. Prior to the fix, this context included the entire application configuration via config()->all(). This meant that any variable defined in Laravel's configuration files—including sensitive secrets like APP_KEY, database credentials, and third-party API keys—was directly accessible to the template renderer.
Furthermore, the parser allowed the instantiation of arbitrary PHP objects and the invocation of methods on those objects. The engine did not enforce a whitelist of safe classes or methods. An attacker could utilize PHP's reflection capabilities (e.g., ReflectionFunction) or the Laravel service container to bypass superficial restrictions and execute system commands. The absence of a strict sandbox meant that once the parser encountered a tag like {{ php }}, or a modifier enabling method calls, it executed the logic with the privileges of the web server user.
The remediation for CVE-2026-28425 involved introducing a strict context separation between developer templates and user content. The key changes were implemented in the Antlers parser and the Cascade data manager.
Previously, the parser would accept content and data without checking the source of the content string. It exposed the full configuration array by default.
// Vulnerable implementation
public function parse($content, $data = [])
{
// All config data is merged into the view context
$context = array_merge($data, config()->all());
return $this->evaluate($content, $context);
}The patch introduces a parseUserContent method and a global state flag isEvaluatingUserData. When this flag is true, the parser enforces strict boundaries.
// Patched implementation (Simplified)
public function parseUserContent($content, $data = [])
{
$this->isEvaluatingUserData = true;
try {
// Use a curated whitelist of config values instead of config()->all()
$safeConfig = Cascade::config();
// The parser now throws exceptions if unsafe methods are called
return $this->evaluate($content, array_merge($data, $safeConfig));
} finally {
$this->isEvaluatingUserData = false;
}
}Additionally, the patch hardens the nocache tag handling. Previously, the Static Caching middleware would process {{ nocache }} blocks even on routes that were explicitly excluded from caching. The fix ensures that the exclusion list is checked before any placeholder replacement occurs, preventing the parser from touching user-controlled nocache blocks on non-cached pages.
To exploit this vulnerability, an attacker requires authentication to the Statamic Control Panel. The required privilege level is low—any role capable of editing entries, configuring forms, or modifying global sets where Antlers parsing is active is sufficient.
Step 1: Identification The attacker identifies a field that supports Antlers parsing. Common targets include:
Step 2: Payload Injection The attacker injects a payload designed to break out of the template logic and execute PHP. A standard Server-Side Template Injection (SSTI) payload for PHP environments often utilizes Reflection to bypass direct function call restrictions.
{{ (new \ReflectionFunction("system"))->invoke("id") }}Alternatively, if the php tag is not explicitly disabled or can be re-enabled via context manipulation:
{{ php }}
echo system('cat /etc/passwd');
{{ /php }}Step 3: Execution Upon saving the entry or previewing the content, the server parses the Antlers syntax. The injected code executes, returning the output of the system command in the rendered HTML or executing silently if the output is suppressed. This grants the attacker Remote Code Execution (RCE) on the underlying server.
The impact of CVE-2026-28425 is rated as High (CVSS 8.0) because it compromises the fundamental security triad: Confidentiality, Integrity, and Availability.
Confidentiality: The vulnerability allows unauthorized access to sensitive data. Attackers can read the contents of .env files, gaining access to database credentials, API keys (e.g., AWS, Stripe), and the APP_KEY used for encryption. This often leads to lateral movement within the network.
Integrity: With RCE, an attacker can modify application code, inject backdoors, deface the website, or alter database records. They can establish persistent access that survives updates or restarts.
Availability: An attacker could delete critical system files, drop database tables, or launch resource-exhaustion attacks, rendering the CMS and the website it powers unavailable.
While the attack requires authentication, the low privilege requirement means that a compromised editor account or a disgruntled employee can escalate their privileges to full server control.
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H| Product | Affected Versions | Fixed Version |
|---|---|---|
Statamic CMS Statamic | < 5.73.11 | 5.73.11 |
Statamic CMS Statamic | >= 6.0.0, < 6.4.0 | 6.4.0 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-94 (Code Injection) |
| CVSS Score | 8.0 (High) |
| Attack Vector | Network (Authenticated) |
| Impact | Remote Code Execution (RCE) |
| EPSS Score | 0.00138 |
| Exploit Status | Proof-of-Concept Available |
The software constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.
PyJWT versions 2.8.0 through 2.12.1 are vulnerable to an unauthenticated Denial of Service (DoS) attack. When verifying detached JSON Web Signatures (JWS) using the unencoded-payload option (RFC 7797, b64=false), the library eagerly decodes the payload segment before verifying the header configuration or the cryptographic signature. This behavior enables a remote, unauthenticated attacker to inject an arbitrarily large payload segment, triggering excessive CPU and memory resource consumption prior to signature validation.
Nodemailer prior to version 8.0.9 contains a security control bypass vulnerability. Transport-level configuration parameters designed to restrict local file system access and remote URL requests are not propagated to all content-resolution execution paths. This failure allows unauthorized local file inclusion and server-side request forgery when the application utilizes specific transports or processing flags.
GHSA-268h-hp4c-crq3 is a Carriage Return Line Feed (CRLF) injection vulnerability in the Nodemailer npm package affecting versions up to and including 8.0.8. The library allows arbitrary email header injection when parsing user-controlled comments within list headers (such as List-Unsubscribe or List-ID). This occurs because list headers bypass standard validation by utilizing an internal 'prepared' flag, causing unsanitized newlines to be emitted directly into the outgoing RFC822 mail stream. This exploit allows remote attackers to inject custom, unauthorized mail headers, disrupting signature checks, bypassing filters, or spoofing parameters.
A logic flaw in PyJWT's PyJWKClient class allows remote unauthenticated attackers to trigger a complete authentication outage. By transmitting a volume of JWTs containing randomized, non-existent Key ID (kid) values, attackers force synchronous outbound JWKS resolution queries. When these queries fail or time out, a defect in the error cleanup code overwrites the local cache of valid signing keys with None, causing a denial of service.
A high-severity type-confusion path traversal vulnerability (CVE-2026-49982 / GHSA-7c78-jf6q-g5cm) exists in the node-tmp package version 0.2.6. The vulnerability allows remote attackers to bypass path validation checks by passing non-string data types such as Arrays or duck-typed Objects into options like prefix, postfix, or template. Because the library relies on the .includes() method without verifying the input type, standard array checks evaluate differently than string checks. Downstream string coercion subsequently restores the traversal sequence, allowing files and directories to be created outside the designated temporary directory root. This can result in arbitrary file writes and potential local file execution depending on application context.
CVE-2026-47347 is an open redirect vulnerability affecting multiple TYPO3 CMS versions. The issue resides in GeneralUtility::sanitizeLocalUrl, where an insufficient blocklist validation implementation fails to prevent browsers from normalizing malformed relative paths into external protocol-relative redirections. Attackers can exploit this to conduct phishing, session hijacking, or credential harvesting campaigns.