Skip to main content

MantisBT CVE-2026-40597

HIGH
Cross-site Scripting (XSS) (CWE-79)
2026-05-11 https://github.com/mantisbt/mantisbt GHSA-9c3j-xm6v-j7j3
7.6
CVSS 4.0 · Vendor: https://github.com/mantisbt/mantisbt
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate with attachment-upload rights
  2. Delivery
    Upload file sniffed as JavaScript MIME
  3. Exploit
    Reference file_download.php URL via existing XSS
  4. Execution
    Victim loads attachment as script-src source
  5. Impact
    Script executes in victim session bypassing CSP

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires two concrete prerequisites that both must be met: (1) a pre-existing XSS or HTML-injection vulnerability elsewhere in the MantisBT instance to inject the script reference, and (2) an authenticated account with permission to upload attachments to an issue, where the uploaded file is crafted so PHP finfo (file_create_finfo()) sniffs it as a valid JavaScript MIME type such as application/javascript - files sniffed as any other type are blocked by the X-Content-Type-Options: nosniff header and will not execute. Limiting factors: this is not exploitable against a hardened instance with no other injection flaw, it needs upload privileges (PR:L, not unauthenticated), and it targets versions <= 2.28.1; the nosniff requirement means arbitrary non-JS payloads do not work, forcing the attacker to produce a file that MIME-sniffs specifically as JavaScript.

Impact

Signals are mixed and point to a real-but-conditional, lower-tier priority. The vendor CVSS 4.0 vector (AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:L, 7.6 High) includes AT:P (Attack Requirements: Present) and PR:L, correctly reflecting that exploitation is not standalone - it requires a pre-existing XSS/HTML injection to chain against AND an authenticated account able to upload attachments. EPSS is very low (0.06%, 20th percentile) and there is no KEV listing and no public exploit identified, consistent with a mitigation-bypass that is only useful in combination with another flaw. The VC:H/VI:H impact rating is arguably aggressive for what is functionally stored XSS; realistic confidentiality/integrity impact is scoped to the victim's session in the browser. No data conflicts materially, but note the dependency: without a separate injection primitive this issue alone does not yield code execution, so it is best treated as a hardening/defense-in-depth fix rather than an urgent independent exploit.

Exploit ScenarioDerived

An authenticated user with attachment-upload rights uploads a specially crafted file to any issue that PHP finfo sniffs as application/javascript, then leverages a separate stored HTML/XSS injection point to reference that file's file_download.php URL inside a <script> tag. When a victim (e.g., a project admin) views the injected page, the browser loads the same-origin attachment as valid JavaScript, satisfying nosniff and the CSP script-src directive, and the attacker's code runs in the victim's session. No public proof-of-concept has been identified at time of analysis.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 23, 2026

Cross-site scripting via a Content Security Policy bypass in MantisBT (versions <= 2.28.1) lets an authenticated attacker who can upload issue attachments turn a pre-existing HTML/XSS injection into full script execution. By uploading a payload that PHP finfo sniffs as a JavaScript MIME type, the file served by file_download.php is accepted by the browser as a valid script-src source, defeating the CSP and nosniff protections. No public exploit identified at time of analysis; EPSS is low (0.06%, 20th percentile) and this is a chaining/defense-in-depth weakness rather than a standalone RCE.

RemediationAI

Vendor-released patch: upgrade MantisBT to 2.28.2, which contains commit 9e3bee2e7b909f4e3596985892b8bc8bee9e0bfe changing file_download.php so text/* attachments are served as text/plain and all other non-audio/video attachments as application/octet-stream, preventing browser script interpretation. The advisory lists no official workarounds; if immediate upgrade is impossible, compensating controls include restricting attachment upload privileges to trusted users only (reduces who can plant a payload, at the cost of collaboration friction), and fronting file_download.php with a proxy/web-server rule that forces Content-Type: application/octet-stream and Content-Disposition: attachment on downloads (forces files to download rather than render inline, which changes user experience for legitimate inline-viewable attachments). Also prioritize eliminating any primary XSS/HTML-injection vulnerabilities, since this bypass is only exploitable when chained. See the GitHub advisory (https://github.com/mantisbt/mantisbt/security/advisories/GHSA-9c3j-xm6v-j7j3) and the patch commit (https://github.com/mantisbt/mantisbt/commit/9e3bee2e7b909f4e3596985892b8bc8bee9e0bfe).

Affected Packages

composer mantisbt/mantisbt fix: 2.28.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in composer

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

MantisBT is a widely used open-source PHP bug-tracking application. The root cause (CWE-79, Improper Neutralization of Input During Web Page Generation) here is not a primary injection but a weakening of a mitigation: attachments retrieved through file_download.php were served with their sniffed MIME type, so a file detected by file_create_finfo()/PHP finfo as application/javascript was returned with a JavaScript content type. Because the app sets X-Content-Type-Options: nosniff, the browser normally refuses to execute non-JS MIME types in a <script> tag - but a genuinely JS-typed attachment satisfies that check and also becomes a same-origin script-src source, bypassing the CSP's script-src directive. The affected package is pkg:composer/mantisbt/mantisbt. The patch (commit 9e3bee2e) forces text/* attachments to text/plain and everything else (except audio/video) to application/octet-stream, preventing inline script interpretation.

Know when PHP gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/mantisbt/mantisbt) PRIMARY 7.6 HIGH
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:L/SC:N/SI:N/SA:N
vuln.today AI 4.4 MEDIUM

AC:H and PR:L because it requires a chained pre-existing XSS plus an authenticated upload account; UI:R as a victim must view the injected page; S:C and C/I:L reflect session-scoped stored XSS.

3.1 AV:N/AC:H/PR:L/UI:R/S:C/C:L/I:L/A:N
4.0 AV:N/AC:H/AT:P/PR:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

Primary rating from Vendor (https://github.com/mantisbt/mantisbt).

CVSS VectorVendor: https://github.com/mantisbt/mantisbt

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

3
CVSS changed
Jul 23, 2026 - 16:22 NVD
7.6 (HIGH)
CVE Published
May 11, 2026 - 19:34 nvd
HIGH
CVE Published
May 11, 2026 - 19:34 cve.org
HIGH 7.6

DescriptionCVE.org

Given any pre-existing XSS / HTML injection vulnerability, an attacker can bypass the Content Security Policy's _script-src_ directive by uploading a crafted attachment to any issue that, when accessed via the _file_download.php_ link, will be downloaded with a valid JavaScript MIME type resulting in script execution.

The uploaded payload must be sniffed as a valid JavaScript MIME type by PHP finfo (see file_create_finfo() API function). Non-JavaScript MIME types will not get imported in a <script> tag by the browser, due to response header X-Content-Type-Options being set to _nosniff_, which requires all imported JavaScript files to be a valid JavaScript MIME type.

Impact

Cross-site scripting

Patches

  • 9e3bee2e7b909f4e3596985892b8bc8bee9e0bfe

Workarounds

None

Credits

Thanks to siunam (Tang Cheuk Hei) for discovering and responsibly reporting the issue.

Executive ViewAI

Why It Matters

MantisBT versions 2.28.1 and earlier contain a cross-site scripting vulnerability that allows authenticated users with file upload privileges to execute arbitrary scripts and compromise user accounts and project data. Although no public exploit identified at time of analysis, the vulnerability eliminates defenses against insider threats and compromised authenticated credentials, creating unacceptable risk for organizations relying on MantisBT for sensitive issue tracking. Vendor-released patches are available to remediate this defense-in-depth weakness, and patching should be prioritized before the vulnerability becomes more widely known.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.1%
Top 80% exploitable
Prevalence
Medium
popular open-source bug tracker, common in dev teams but not ubiquitous
Threat Intel
1
1 source
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
High

Priority Score

38
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +38
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Affected Products (CPE)CVE.org

pkg:composer/mantisbt_mantisbt

More in PHP

View all
CVE-2019-11043 CRITICAL POC
9.8 Oct 28

In PHP versions 7.1.x below 7.1.33, 7.2.x below 7.2.24 and 7.3.x below 7.3.11 in certain configurations of FPM setup it

CVE-2012-1823 CRITICAL POC
9.8 May 11

sapi/cgi/cgi_main.c in PHP before 5.3.12 and 5.4.x before 5.4.2, when configured as a CGI script (aka php-cgi), does not

CVE-2016-1555 CRITICAL POC
9.8 Apr 21

(1) boardData102.php, (2) boardData103.php, (3) boardDataJP.php, (4) boardDataNA.php, and (5) boardDataWW.php in Netgear

CVE-2018-11138 CRITICAL POC
9.8 May 31

The '/common/download_agent_installer.php' script in the Quest KACE System Management Appliance 8.0.318 is accessible by

CVE-2024-11680 CRITICAL POC
9.8 Nov 26

ProjectSend versions prior to r1720 are affected by an improper authentication vulnerability. Rated critical severity (C

CVE-2025-49113 CRITICAL POC
9.9 Jun 02

Roundcube Webmail contains a critical PHP object deserialization vulnerability (CVE-2025-49113, CVSS 9.9) that allows au

CVE-2017-9841 CRITICAL POC
9.8 Jun 27

Util/PHP/eval-stdin.php in PHPUnit before 4.8.28 and 5.x before 5.6.3 allows remote attackers to execute arbitrary PHP c

CVE-2025-0108 HIGH POC
8.8 Feb 12

Palo Alto Networks PAN-OS management web interface contains an authentication bypass allowing unauthenticated attackers

CVE-2021-25298 HIGH POC
8.8 Feb 15

Nagios XI version xi-5.7.5 is affected by OS command injection. Rated high severity (CVSS 8.8), this vulnerability is re

CVE-2021-25296 HIGH POC
8.8 Feb 15

Nagios XI version xi-5.7.5 is affected by OS command injection. Rated high severity (CVSS 8.8), this vulnerability is re

CVE-2013-4983 CRITICAL POC
10.0 Sep 10

The get_referers function in /opt/ws/bin/sblistpack in Sophos Web Appliance before 3.7.9.1 and 3.8 before 3.8.1.1 allows

CVE-2023-6553 CRITICAL POC
9.8 Dec 15

The Backup Migration plugin for WordPress is vulnerable to Remote Code Execution in all versions up to, and including, 1

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy