Skip to main content
Vulnerability Database/CVE-2026-19541

CVE-2026-19541: Mattermost OAuth Secret Exposure Vulnerability

CVE-2026-19541 is an authentication bypass flaw in Mattermost that allows authenticated users to expose OAuth client secrets by redirecting token URLs to attacker-controlled endpoints. This article covers technical details, affected versions, impact analysis, and mitigation strategies.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-19541 Overview

CVE-2026-19541 affects multiple Mattermost releases where the platform fails to require re-entry of the stored client secret when validating an outgoing OAuth connection. An authenticated user with permission to manage outgoing OAuth connections can retrieve the stored secret by pointing the token URL at an attacker-controlled endpoint and triggering validation. The flaw is tracked under Mattermost Advisory MMSA-2026-00761 and maps to [CWE-201] Insertion of Sensitive Information Into Sent Data.

Critical Impact

An authenticated administrator of outgoing OAuth connections can exfiltrate stored OAuth client secrets to an external, attacker-controlled URL, enabling downstream abuse of integrated third-party services.

Affected Products

  • Mattermost 11.9.x versions up to and including 11.9.1
  • Mattermost 11.8.x versions up to and including 11.8.5, and 11.7.x versions up to and including 11.7.10
  • Mattermost 11.10.x versions up to and including 11.10.1

Discovery Timeline

  • 2026-10-16 - CVE-2026-19541 published to the National Vulnerability Database (NVD)
  • 2026-10-16 - Last updated in NVD database

Technical Details for CVE-2026-19541

Vulnerability Analysis

Mattermost supports outgoing OAuth connections that store a client secret for authenticating to third-party token endpoints. The validation workflow replays the stored secret against the configured token URL to confirm the connection works. The vulnerable builds do not require operators to re-enter the secret before validation and do not restrict the destination URL to the originally configured host.

An authenticated user holding the permission to manage outgoing OAuth connections can edit the token URL on an existing connection, redirect it to an endpoint they control, and trigger validation. The server then transmits the stored client secret to that endpoint as part of a standard OAuth token request. The attacker captures the secret in server logs or request bodies.

The vulnerability is categorized as information disclosure. It does not grant code execution on the Mattermost host, but exposes credentials that typically authorize access to connected SaaS platforms, internal APIs, or identity brokers.

Root Cause

The root cause is a design flaw in the outgoing OAuth validation workflow. The server trusts the authenticated administrator to supply a legitimate token URL and reuses the stored secret without additional verification. There is no re-authentication step requiring the operator to re-enter the secret, and no allow-list binding the secret to its original token endpoint.

Attack Vector

Exploitation requires network access to the Mattermost instance and an authenticated session with permission to manage outgoing OAuth connections. The attacker edits an existing connection, replaces the token URL with a listener they own, and invokes the validation endpoint. The Mattermost server performs a server-side HTTP POST that includes the stored client_secret. The attacker reads the secret from their listener and reuses it against the original OAuth provider.

No verified public exploit code is available. The Mattermost security advisory documents the issue and corresponding fixed releases.

Detect Identity Attacks the Moment Authentication Fails

Singularity™ Identity surfaces credential misuse, lateral movement, and privilege escalation in real time, so you can contain the breach before it spreads.

Stop Identity Attacks

Detection Methods for CVE-2026-19541

Indicators of Compromise

  • Outgoing OAuth connection records with recently modified token_url values that no longer match the original third-party provider domain.
  • Audit log entries showing validation of outgoing OAuth connections immediately after an edit by a non-standard administrator account.
  • Outbound HTTPS requests from the Mattermost server to unexpected hosts carrying OAuth grant_type=client_credentials payloads.

Detection Strategies

  • Baseline the set of legitimate OAuth provider hostnames and alert on any outgoing OAuth connection whose token URL is changed to a host outside that list.
  • Correlate administrator activity logs with outbound network connections from the Mattermost application tier to flag secret-exfiltration patterns.
  • Review Mattermost audit logs for repeated OutgoingOAuthConnection validation events against the same connection ID in short succession.

Monitoring Recommendations

  • Forward Mattermost audit logs and reverse-proxy access logs to a centralized analytics platform for retention and query.
  • Monitor egress traffic from Mattermost servers for connections to newly observed or low-reputation domains.
  • Alert on privilege changes that grant the manage-outgoing-OAuth-connections permission to additional accounts.

How to Mitigate CVE-2026-19541

Immediate Actions Required

  • Upgrade Mattermost to a fixed release above 11.9.1, 11.8.5, 11.7.10, or 11.10.1 as published in the Mattermost security advisory.
  • Rotate all client secrets for existing outgoing OAuth connections, since previously stored secrets may already have been exfiltrated.
  • Audit the list of users holding the permission to manage outgoing OAuth connections and remove it from accounts that do not require it.

Patch Information

Mattermost has released fixed versions addressing MMSA-2026-00761. Administrators should consult the Mattermost Security Updates page for the exact patched build numbers that correspond to each supported release train and apply them according to the vendor's upgrade guidance.

Workarounds

  • Restrict the manage-outgoing-OAuth-connections permission to a minimal, trusted administrator group until patching is complete.
  • Apply egress filtering on Mattermost servers so that outgoing OAuth validation requests can only reach approved third-party token endpoints.
  • Review and, where feasible, delete non-essential outgoing OAuth connections to reduce the number of stored secrets at risk.
bash
# Example egress allow-list concept using iptables on the Mattermost host
# Replace provider.example.com with your approved OAuth token endpoints
ALLOWED_HOST="provider.example.com"
ALLOWED_IP=$(dig +short "$ALLOWED_HOST" | head -n1)

iptables -A OUTPUT -p tcp --dport 443 -d "$ALLOWED_IP" -j ACCEPT
iptables -A OUTPUT -p tcp --dport 443 -j REJECT

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.