CVE-2026-58037: MediaWiki Cross-Site Scripting (XSS) in Log Formatters and Language Components
MediaWiki contains a cross-site scripting (XSS) vulnerability in multiple logging and language components. An attacker can inject malicious scripts into log entries or language-related output that execute in the browsers of users viewing those pages, potentially stealing session tokens, performing actions on behalf of logged-in users, or redirecting them to malicious sites. User interaction is required—the victim must view a page containing the injected payload—but no special permissions are needed to exploit this flaw.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 6.1 MEDIUM · CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Weaknesses (CWE)
- CWE-79
- Affected products
- 2 configuration(s)
- Published / Modified
- 2026-07-01 / 2026-07-09
NVD description (verbatim)
Improper Neutralization of Input During Web Page Generation (XSS or 'Cross-site Scripting') vulnerability in Wikimedia Foundation MediaWiki. This vulnerability is associated with program files includes/Language/Language.Php, includes/Logging/BlockLogFormatter.Php, includes/Logging/LogFormatter.Php, includes/Logging/PatrolLogFormatter.Php, includes/Logging/RenameuserLogFormatter.Php, includes/Logging/TagLogFormatter.Php, includes/Specials/SpecialVersion.Php. This issue affects MediaWiki: from * before 1.46.0, 1.45.4, 1.44.6, 1.43.9.
1 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
This XSS vulnerability (CWE-79) spans seven files in MediaWiki's codebase: Language.php, BlockLogFormatter.php, LogFormatter.php, PatrolLogFormatter.php, RenameUserLogFormatter.php, TagLogFormatter.php, and SpecialVersion.php. The vulnerability results from improper sanitization of user-controlled input during web page generation. Attackers can craft inputs that bypass output encoding, allowing arbitrary JavaScript execution in the context of the MediaWiki application. The CVSS 3.1 score of 6.1 (MEDIUM) reflects network accessibility, low attack complexity, and lack of privilege requirements, tempered by the requirement for user interaction and limited impact scope due to same-site restrictions on some attack vectors.
Business impact
Exploitation could compromise user accounts and administrator trust. Attackers may harvest session credentials, perform unauthorized edits or administrative actions, deface pages, or redirect users to phishing or malware distribution sites. For wiki operators, this undermines data integrity and user confidence, especially if logged events or version pages are targets. Organizations relying on MediaWiki for documentation or knowledge management face potential information disclosure or tampering.
Affected systems
All MediaWiki installations before version 1.46.0 are affected. Specific earlier release lines vulnerable include versions before 1.45.4, 1.44.6, and 1.43.9. Organizations running any version in the 1.43.x through 1.45.x series or earlier versions in the main branch must evaluate their patch status immediately.
Exploitability
This vulnerability requires user interaction and network access but no authentication or special privileges. An attacker can craft a malicious log entry or inject payload into a language-dependent output field. When an administrator, moderator, or regular user views the affected page, the script executes in their browser. The attack surface spans logging functionality used frequently by wiki operators, making discovery and exploitation straightforward for motivated attackers. However, browser same-origin policies and content security headers (if properly configured) may provide partial mitigation.
Remediation
Upgrade MediaWiki immediately to a patched version. Verify against your current installation version and apply the smallest applicable patch: version 1.46.0 or later, 1.45.4 or later, 1.44.6 or later, or 1.43.9 or later. After patching, clear browser caches and ensure all users are logged out and back in to avoid serving cached malicious content. Review recent log entries for any suspicious or unusual content that might indicate prior exploitation attempts.
Patch guidance
Consult the Wikimedia Foundation security advisory for your specific version branch. Test patches in a staging environment before production deployment. MediaWiki upgrades should follow standard procedures: backup the database, test the upgrade, review any configuration changes, and validate that extensions remain compatible. For organizations on extended support, verify that your release line is still receiving security updates; end-of-life versions will not receive patches.
Detection guidance
Monitor for suspicious patterns in log tables and version page access logs. Look for script-like syntax or HTML entities (e.g., <script>, <, onerror=) in log entry text, edit summaries, or user rename operations. Use web application firewalls to detect XSS-like payloads in request parameters. Review server and application logs for unusual access to the affected PHP files. If a staging or test instance is compromised, assume the production wiki may also be at risk and review edit and log histories for injected content.
Why prioritize this
Although the CVSS score is MEDIUM (6.1), the vulnerability affects critical administrative and logging functions relied upon by wiki operators daily. The lack of privilege requirements and low attack complexity means opportunistic attackers can exploit this widely. Log entries and version pages are frequently accessed by trusted users, amplifying the potential for credential theft or account compromise. For any public or semi-public MediaWiki instance, this should be treated as a high-priority patch.
Risk score, explained
The CVSS 3.1 score of 6.1 reflects: (1) network-based attack vector requiring no special access; (2) low attack complexity with no race conditions or special setup; (3) no privilege requirement; (4) user interaction required (victim must view the malicious page); (5) changed security scope (the XSS executes in the context of the MediaWiki application, affecting other users and the application itself); (6) low confidentiality impact (session tokens or non-sensitive data may be exfiltrated); (7) low integrity impact (user actions can be forged, but systemic damage is limited); (8) no availability impact. The MEDIUM rating reflects the combination of ease of exploitation offset by user interaction requirements and limited blast radius per incident.
Frequently asked questions
Can I work around this vulnerability without upgrading?
Partial mitigations include disabling log viewing for non-administrators, enforcing strict Content Security Policies, and using a Web Application Firewall to filter script-like payloads. However, these do not eliminate the underlying flaw. Upgrading is the only reliable fix.
How can I tell if my MediaWiki has been exploited?
Review recent entries in the log tables (logging table in the database) for HTML entities, script tags, or JavaScript keywords. Check access logs for patterns of administrators or moderators viewing the same page repeatedly. Use grep or database queries to search for suspicious characters like <, >, javascript:, or onerror= in log entries.
Are third-party MediaWiki extensions affected?
This CVE addresses core MediaWiki components. Some extensions may have their own XSS vulnerabilities, but they are not part of this issue. After patching, audit any custom or third-party extensions for similar input-handling weaknesses.
What is the difference between versions 1.46.0, 1.45.4, and 1.44.6?
These are different release branches within MediaWiki. You should apply the patch relevant to your current version. If you are on 1.45.x, upgrade to 1.45.4 or later; if on 1.44.x, upgrade to 1.44.6 or later. Plan a longer-term upgrade to a newer branch if your current branch is nearing end-of-life.
This analysis is based on vulnerability data published as of July 2026. CVSS scores and severity assessments reflect industry-standard methodologies but may not capture all contextual risk factors specific to your environment. This document does not constitute security advice specific to your organization; consult your security team and the Wikimedia Foundation official advisory before taking remediation actions. No exploit code or proof-of-concept techniques are provided. Always test patches in a non-production environment before deployment. SEC.co assumes no liability for decisions made based on this intelligence. Source: NVD (public-domain), retrieved 2026-08-10. Analysis generated by SEC.co (claude-haiku-4-5).
Related vulnerabilities
- CVE-2026-14358MEDIUMMediaWiki Charts Extension XSS Vulnerability – Patch Guide
- CVE-2026-58028MEDIUMMediaWiki XSS Vulnerability in API and Page Rendering
- CVE-2026-58030MEDIUMXSS Vulnerability in Wikimedia SyntaxHighlight_GeSHi Extension
- CVE-2026-58031MEDIUMMediaWiki API Sandbox XSS Vulnerability (CVSS 5.4)
- CVE-2026-58032MEDIUMMediaWiki XSS Vulnerability in API Module – Patch Guidance
- CVE-2026-58034MEDIUMCheckUser Cross-Site Scripting (XSS) Vulnerability in MediaWiki
- CVE-2026-58035MEDIUMMediaWiki Special:Block XSS Vulnerability (CVSS 4.8)
- CVE-2026-58038MEDIUMMediaWiki Timeline XSS Vulnerability—CVSS 6.1 Patch Guidance