Security Resilience

CVE-2025-12421

Auth Bypass in Mattermost Server 10.5.0 – 10.5.13

Published
27 November 2025
Modified
19 October 2026
Patch / advisory
CVSS Score v3.1 9.9
Click a component to see what it means
Raw vectorCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
EPSS Score 0.0045 40th percentile
Risk Priority 68 floored blend · peak EPSS

CVSS and EPSS are reproduced from their sources (NVD, FIRST EPSS). EPSS, Forum of Incident Response and Security Teams (FIRST), epss.first.org. Risk Priority is our own derived reading, not an NVD score.

Summary

CVE-2025-12421 is a critical-severity Incorrect Implementation of Authentication Algorithm (CWE-303) vulnerability in Mattermost Server. Its CVSS base score is 9.9 (Critical).

Operationally, exploitation aligns with the MITRE ATT&CK technique Exploit Public-Facing Application (T1190); ranked at the 40th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog.

The strongest mitigations our analysis identified map to SA-11 (Developer Testing and Evaluation) and SA-15 (Development Process, Standards, and Tools) — see the control section below for these in your framework.

Deeper analysis AI-assisted summary

Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.

CVE-2025-12421 is a critical authentication vulnerability in Mattermost, affecting versions 11.0.x up to and including 11.0.2, 10.12.x up to 10.12.1, 10.11.x up to 10.11.4, and 10.5.x up to 10.5.12. The issue arises from a failure to verify that the token used during the code exchange originates from the same authentication flow. This is classified under CWE-303 (Incorrect Check of Function Return Value) and carries a CVSS v3.1 base score of 9.9 (AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H). Exploitation requires the ExperimentalEnableAuthenticationTransfer feature to be enabled (default: enabled) and RequireEmailVerification to be disabled (default: disabled).

An authenticated user with low privileges can exploit this vulnerability remotely over the network with low attack complexity and no user interaction. The attacker crafts a specially formatted email address while switching authentication methods, then sends a request to the /users/login/sso/code-exchange endpoint. This allows takeover of another user's account by hijacking the authentication flow, potentially granting full access to the victim's data and privileges due to the changed scope and high impacts on confidentiality, integrity, and availability.

Mattermost has published details on mitigations in their security updates, available at https://mattermost.com/security-updates. Security practitioners should review this advisory for patch information and configuration guidance to address the vulnerability.

OWASP Top 10 for Web (2025)

EU & UK References

Vulnerability Data

Mattermost versions 11.0.x <= 11.0.2, 10.12.x <= 10.12.1, 10.11.x <= 10.11.4, 10.5.x <= 10.5.12 fail to to verify that the token used during the code exchange originates from the same authentication flow, which allows an authenticated user to perform account…

more

takeover via a specially crafted email address used when switching authentication methods and sending a request to the /users/login/sso/code-exchange endpoint. The vulnerability requires ExperimentalEnableAuthenticationTransfer to be enabled (default: enabled) and RequireEmailVerification to be disabled (default: disabled).

CWE(s)

Related Threats

MITRE ATT&CK Enterprise Techniques

MITRE ATT&CK v20.0

T1190 Exploit Public-Facing Application Initial Access
Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network.
T1212 Exploitation for Credential Access Credential Access
Adversaries may exploit software vulnerabilities in an attempt to collect credentials.
T1021.005 VNC Lateral Movement
Adversaries may use [Valid Accounts](https://attack.
T1210 Exploitation of Remote Services Lateral Movement
Adversaries may exploit remote services to gain unauthorized access to internal systems once inside of a network.
T1602.001 SNMP (MIB Dump) Collection
Adversaries may target the Management Information Base (MIB) to collect and/or mine valuable information in a network managed using Simple Network Management Protocol (SNMP).
Derived from this CVE’s CWE(s) via the direct CWE→ATT&CK cross-walk.

CVEs Like This One

CVE-2025-2571Same product: Mattermost Mattermost Server
CVE-2025-12419Same product: Mattermost Mattermost Server
CVE-2025-3230Same product: Mattermost Mattermost Server
CVE-2025-14273Same product: Mattermost Mattermost Server
CVE-2026-27656Same product: Mattermost Mattermost Server
CVE-2025-2475Same product: Mattermost Mattermost Server
CVE-2026-0999Same product: Mattermost Mattermost Server
CVE-2024-36250Same product: Mattermost Mattermost Server
CVE-2026-9571Same product: Mattermost Mattermost Server
CVE-2026-6334Same product: Mattermost Mattermost Server

Affected Assets

mattermost
mattermost server
10.5.0 — 10.5.13 · 10.11.0 — 10.11.5 · 10.12.0 — 10.12.2

Mitigating Controls

Mitigating Controls (NIST 800-53 r5)

Our mappings, made for this CVE.

Developer testing and evaluation at post-design stages directly uncovers incorrect implementations of required authentication algorithms.

Requiring documented development processes, standards, and tools reduces the chance that an established authentication algorithm is coded incorrectly.

Mitigating Controls (NIST CSF 2.0)

Our mappings, derived directly from the weakness types (CWEs) cited in the NVD entry via our CWE→CSF cross-walk — links open the control.

PR.PS-06 mostly match
blocks

Secure SDLC practices directly require correct implementation of authentication algorithms.

Mitigating Controls (ISO/IEC 27001:2022 Annex A)

Our mappings, derived directly from the weakness types (CWEs) cited in the NVD entry via our CWE→ISO cross-walk — links open the control.

finds

Security testing can detect flawed authentication implementations but does not prevent them by itself.

blocks

A.8.20 governs network-level controls (firewalls, segregation, logging, protocol hardening); CWE-303 is a code-level defect in the implementation of an authentication algorithm, which network controls neither reach nor stop from being exploited.

prevents

Secure coding practices reduce the likelihood of incorrect authentication algorithm implementation.

prevents

A.8.30 contracts for secure design, coding and testing practices (8.25–8.29) in outsourced work, which reduces ordinary implementation defects like an incorrectly implemented authentication algorithm the same way those practices do, but the effect is bounded by the fallibility of the practices and the clause's dependence on those other controls being properly implemented — the declared ceiling for A.8.30 on `prevents`.

blocks

Secure authentication control directly requires correct implementation of authentication algorithms.

finds

A.8.8's reach is DISCLOSURE (vendor-published flaws in third-party components) plus the penetration-testing route it names; CWE-303 is primarily a first-party implementation defect whose high-rated detection methods (code review, static analysis) belong to A.8.28/A.8.29, not A.8.8. A minority of instances are found: those in third-party components carrying a published CVE, plus a further slice surfaced by penetration testing where the authentication bypass is observable from outside.

References