MattermostApplication

CVE-2024-39777

CRITICAL · 9.6 CVSS v3.1 Published 2024-08-01
Fix available
A fix is available. Upgrade to 9.5.7 / 9.7.6 or later.
See remediation →
100/100
Remediation priority · Urgent
Remotely reachable Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Mattermost versions 9.9.x <= 9.9.0, 9.5.x <= 9.5.6, 9.7.x <= 9.7.5 and 9.8.x <= 9.8.1 fail to disallow unsolicited invites to expose access to local channels, when shared channels are enabled, which allows a malicious remote to send an invite with the ID of an existing local channel, and that local channel will then become shared without the consent of the local admin.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · moderate confidence

Mattermost fails to validate that channel invites from remote servers are for new channels rather than existing local channels when shared channels are enabled. A malicious remote server can send an invite containing an existing local channel's ID, causing that channel to become shared without local administrator consent, exposing its contents to the remote server.

MitigationUpgrade to the patched versions (9.9.1, 9.8.2, 9.7.6, 9.5.7 and later). Until patched, audit existing shared channels to detect unauthorized ones and consider disabling shared channels if not required.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
MattermostApplication
Affected:>= 9.5.0, < 9.5.7>= 9.7.0, < 9.7.6>= 9.8.0, < 9.8.2= 9.9.0

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
Low
User interaction
None
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:N

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Determine the installed Mattermost version
    Run `grep -i version /opt/mattermost/version.go` or check the Mattermost System Console under About > Mattermost, or use the API endpoint `GET /api/v4/system/version`
    Affected if The installed version falls within >= 9.5.0 and < 9.5.7, OR >= 9.7.0 and < 9.7.6, OR >= 9.8.0 and < 9.8.2, OR exactly 9.9.0
  2. Verify if Shared Channels feature is enabled
    In the Mattermost System Console, navigate to Environment > Webhook > Enable Shared Channels, or query the configuration via the API or config file for `ServiceSettings.EnableSharedChannels` set to true
    Affected if Shared Channels is enabled (the vulnerability only applies when this feature is turned on)
  3. Identify all shared channels in the system
    Query the database for channels where `remote_id` is not null (e.g., `SELECT Id, DisplayName, CreateAt FROM Channels WHERE RemoteId IS NOT NULL;`) or use the API `GET /api/v4/channels?include_shared_channels=true`
    Affected if Any channel exists with a non-null remote_id indicating it was shared from a remote server
  4. Review audit logs for unexpected shared channel invite events
    Check the audit logs (table Audit or log files) for events of type `shared_channel_invite` or `shared_channel_received` that occurred without corresponding admin approval actions, particularly for invites targeting existing local channel IDs
    Affected if Audit logs show shared channel invites for channels that were not intentionally shared by a local admin

A user is affected if their Mattermost version is in the vulnerable range AND Shared Channels is enabled AND an unauthorized shared channel exists or appears in audit logs.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 9.5.7 / 9.7.6 / 9.8.2 or later
Fixed in 9.5.79.7.69.8.2
Interim mitigation

Upgrade to the patched versions (9.9.1, 9.8.2, 9.7.6, 9.5.7 and later). Until patched, audit existing shared channels to detect unauthorized ones and consider disabling shared channels if not required.

Recommended fix High confidence

Upgrade to one of: Mattermost 9.5.7, 9.7.6, 9.8.2, or 9.9.1 (or later) depending on your current branch

  1. 1. Identify the current Mattermost version by checking the System Console > About page or using the mmctl CLI tool
  2. 2. For versions 9.5.0-9.5.6: Upgrade to Mattermost version 9.5.7 or later
  3. 3. For versions 9.7.0-9.7.5: Upgrade to Mattermost version 9.7.6 or later
  4. 4. For versions 9.8.0-9.8.1: Upgrade to Mattermost version 9.8.2 or later
  5. 5. For version 9.9.0: Upgrade to Mattermost version 9.9.1 or later
  6. 6. After upgrade, verify the System Console > Shared Channels settings to confirm the patch is applied
  7. 7. Review shared channel connections to ensure no unauthorized channels were shared during the vulnerability window
  8. 8. Consider rotating API keys and tokens as a precautionary measure
Caveat Review Mattermost release notes before upgrading as minor version upgrades may include schema changes or feature modifications that could affect custom integrations

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Mattermost Scoped from the published advisory
  • Consultation3.0 h
  • Implementation12.0 h
  • Testing10.0 h
  • Review / QA5.0 h
30.0 hours of engineering $5,160
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $8,256.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2024-39777 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2024-39777 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data