CVE-2026-49273: MantisBT Remote Code Execution Vulnerability

HIGH
Advisory Identifier: GHSA-v84x-qvhg-f36r
CWE-95
Published
Advisory Summary

CVE-2026-49273 is a HIGH remote code execution vulnerability (CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')) affecting MantisBT libraries in the Packagist ecosystem. The issue involves remote code execution via eval() class hoisting in adm_config_set.php. Remediation is available by upgrading affected packages to version 2.28.4.

CVE-2026-49273 at a Glance

CVE Identifier CVE-2026-49273
GHSA Identifier GHSA-v84x-qvhg-f36r
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')
Affected Product MantisBT
Package Ecosystem Packagist
Published Date
Last Updated

How to Fix CVE-2026-49273

To remediate this vulnerability, upgrade all affected MantisBT dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

mantisbt/mantisbt fixed: 2.28.4
Upgrade mantisbt/mantisbt to 2.28.4
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for mantisbt/mantisbt

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-49273, inspect your project dependencies for MantisBT:

inspect dependencies for mantisbt/mantisbt

Analyze the terminal output to locate any version of MantisBT in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.28.4), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection'), where the product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes code syntax before using the input in a dynamic evaluation call (e.g. "eval"). In MantisBT, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

MantisBT 2.28.3 and earlier contains a remote code execution vulnerability in the admin "Manage Configuration" feature (adm_config_set.php). When setting a configuration value with a non-string type (integer, float, complex), the value is passed through ConfigParser -> Tokenizer, which calls *eval()* with a `return;` prefix intended to prevent code execution. However, PHP hoists function and class declarations at compile time, even past a *return* statement. An attacker can define a class in the eval()'d code that hijacks a class loaded later via PHP's autoloader, achieving arbitrary code execution. This vulnerability requires administrator access to the web UI (adm_config_set.php). The REST API's ConfigsSetCommand does NOT use Tokenizer/eval() and is not affected. ### Impact - Remote code execution as the web server user (www-data) from an authenticated administrator session ### Patches - https://github.com/mantisbt/mantisbt/commit/78c0af63d1fe0118004744cab21ca3bf2cea0f5c ### Workarounds None. ### Resources - https://mantisbt.org/bugs/view.php?id=37122 ### Credits McCaulay Hudson (@_McCaulay) of watchTowr

CVE-2026-49273 Affected MantisBT Versions

1 component(s)
Fixed Versions:
2.28.4
Product / Package Ecosystem Affected Versions Fixed Version
mantisbt/mantisbt
Packagist
≥ 1.3.0
< 2.28.4
2.28.4

References

Frequently Asked Questions

What is CVE-2026-49273?
CVE-2026-49273 is a security vulnerability in MantisBT involving Remote Code Execution via eval() Class Hoisting in adm_config_set.php under CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection').
Which MantisBT versions are affected?
Affected versions include releases prior to 2.28.4 across affected packages: mantisbt/mantisbt.
What version fixes CVE-2026-49273?
Upgrading to 2.28.4 (or the latest patched release for your respective branch) resolves the vulnerability.
Is mantisbt/mantisbt affected?
Yes, mantisbt/mantisbt is affected in releases prior to 2.28.4. Upgrade your dependency to 2.28.4 or later.
What CWE is associated with CVE-2026-49273?
CVE-2026-49273 is classified under CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection') (The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes code syntax before using the input in a dynamic evaluation call (e.g. "eval").).
How can I check Packagist dependencies for CVE-2026-49273?
Run the dependency tree command: 'inspect dependencies for mantisbt/mantisbt'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-v84x-qvhg-f36r",
  "modified" : "2026-07-15T16:52:24Z",
  "published" : "2026-07-15T16:52:24Z",
  "aliases" : [ "CVE-2026-49273" ],
  "summary" : "MantisBT: Remote Code Execution via eval() Class Hoisting in adm_config_set.php",
  "details" : "MantisBT 2.28.3 and earlier contains a remote code execution vulnerability in the admin \"Manage Configuration\" feature (adm_config_set.php). When setting a configuration value with a non-string type (integer, float, complex), the value is passed through ConfigParser -> Tokenizer, which calls *eval()* with a `return;` prefix intended to prevent code execution.\n\nHowever, PHP hoists function and class declarations at compile time, even past a *return* statement. An attacker can define a class in the eval()'d code that hijacks a class loaded later via PHP's autoloader, achieving arbitrary code execution.\n\nThis vulnerability requires administrator access to the web UI (adm_config_set.php). The REST API's ConfigsSetCommand does NOT use Tokenizer/eval() and is not affected.\n\n### Impact\n- Remote code execution as the web server user (www-data) from an authenticated administrator session\n\n### Patches\n- https://github.com/mantisbt/mantisbt/commit/78c0af63d1fe0118004744cab21ca3bf2cea0f5c\n\n### Workarounds\nNone. \n\n### Resources\n- https://mantisbt.org/bugs/view.php?id=37122\n\n### Credits\nMcCaulay Hudson (@_McCaulay) of watchTowr",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "mantisbt/mantisbt"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.3.0"
      }, {
        "fixed" : "2.28.4"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 2.28.3"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/mantisbt/mantisbt/security/advisories/GHSA-v84x-qvhg-f36r"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/mantisbt/mantisbt/commit/78c0af63d1fe0118004744cab21ca3bf2cea0f5c"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/mantisbt/mantisbt"
  }, {
    "type" : "WEB",
    "url" : "https://mantisbt.org/bugs/view.php?id=37122"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-95" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-07-15T16:52:24Z",
    "nvd_published_at" : null
  }
}