Mattermost <=10.8.x RCE via Path Traversal in Archive Extractor
CVE-2025-4981 Published on June 20, 2025
Path Traversal Leading to RCE by Any Authenticated Mattermost User
Mattermost versions 10.5.x <= 10.5.5, 9.11.x <= 9.11.15, 10.8.x <= 10.8.0, 10.7.x <= 10.7.2, 10.6.x <= 10.6.5 fail to sanitize filenames in the archive extractor which allows authenticated users to write files to arbitrary locations on the filesystem via uploading archives with path traversal sequences in filenames, potentially leading to remote code execution. The vulnerability impacts instances where file uploads and document search by content is enabled (FileSettings.EnableFileAttachments = true and FileSettings.ExtractContent = true). These configuration settings are enabled by default.
Vulnerability Analysis
CVE-2025-4981 can be exploited with network access, and requires small amount of user privileges. This vulnerability is considered to have a low attack complexity. The potential impact of an exploit of this vulnerability is considered to be critical as this vulnerability has a high impact to the confidentiality, integrity and availability of this component.
Weakness Type
What is a DLL preloading Vulnerability?
The product uses a fixed or controlled search path to find resources, but one or more locations in that path can be under the control of unintended actors.
CVE-2025-4981 has been classified to as a DLL preloading vulnerability or weakness.
Products Associated with CVE-2025-4981
stack.watch emails you whenever new vulnerabilities are published in Mattermost Server or MatterMost. Just hit a watch button to start following.
Affected Versions
Mattermost:- Version 10.5.0, <= 10.5.5 is affected.
- Version 9.11.0, <= 9.11.15 is affected.
- Version 10.8.0, <= 10.8.0 is affected.
- Version 10.7.0, <= 10.7.2 is affected.
- Version 10.6.0, <= 10.6.5 is affected.
- Version 10.9.0 is unaffected.
- Version 10.5.6 is unaffected.
- Version 9.11.16 is unaffected.
- Version 10.8.1 is unaffected.
- Version 10.7.3 is unaffected.
- Version 10.6.6 is unaffected.
Exploit Probability
EPSS (Exploit Prediction Scoring System) scores estimate the probability that a vulnerability will be exploited in the wild within the next 30 days. The percentile shows you how this score compares to all other vulnerabilities.