# CVE-2025-4981: Path Traversal Leading to RCE by Any Authenticated Mattermost User

- Severity: Critical 9.9 (CVSS:3.1, scored by Mattermost) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.06%, higher than 65% of CVEs (2026-12-01)
- Published: 2025-06-20T10:27:13.471Z
- Modified: 2026-06-17T09:34:26.060Z
- Also known as: GHSA-qh58-9v3j-wcjc, GO-2025-3769
- Weaknesses: CWE-427
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact total
- Assigned by: Mattermost

## Description

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.

(As written by CVE List.)

## Affected

- Mattermost Mattermost: from 10.5.0 up to 10.5.5; from 9.11.0 up to 9.11.15; from 10.8.0 up to 10.8.0; from 10.7.0 up to 10.7.2; from 10.6.0 up to 10.6.5 (not affected: 10.9.0; 10.5.6; 9.11.16; 10.8.1; 10.7.3; 10.6.6)
- github.com/mattermost/mattermost-server (Go): before 0.0.0-20250519205859-65aec10162f6; from 9.11.0+incompatible before 9.11.16+incompatible; from 10.5.0+incompatible before 10.5.6+incompatible; from 10.6.0+incompatible before 10.6.6+incompatible; from 10.7.0+incompatible before 10.7.3+incompatible; from 10.8.0+incompatible before 10.8.1+incompatible
- github.com/mattermost/mattermost/server/v8 (Go): before 8.0.0-20250519205859-65aec10162f6; from 10.5.0 before 10.5.6; from 9.11.0 before 9.11.16; from 10.8.0 before 10.8.1; from 10.7.0 before 10.7.3; from 10.6.0 before 10.6.6
- github.com/mattermost/mattermost-server/v5 (Go): all versions
- github.com/mattermost/mattermost-server/v6 (Go): all versions
- mattermost mattermost_server: from 9.11.0 before 9.11.16; from 10.5.0 before 10.5.6; from 10.6.0 before 10.6.6; from 10.7.0 before 10.7.3; 10.8.0

## Every score

- Mattermost: CVSS:3.1 9.9 Critical `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H`
- GitHub: CVSS:3.1 9.9 Critical `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H`

## References

- <https://mattermost.com/security-updates> (vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2025-4981> (advisory)
- <https://github.com/mattermost/mattermost/commit/65aec10162f612d98edf91cc66bf7e781868448b> (web)
- <https://github.com/mattermost/mattermost> (package)
- <https://github.com/advisories/GHSA-qh58-9v3j-wcjc> (advisory)

## Sources

- CVE List: [CVE-2025-4981](https://www.cve.org/CVERecord?id=CVE-2025-4981), CVE Terms of Use, modified 2025-06-20
- GitHub Advisory Database: [GHSA-qh58-9v3j-wcjc](https://github.com/advisories/GHSA-qh58-9v3j-wcjc), CC-BY-4.0, modified 2025-07-28
- Go Vulnerability Database: [GO-2025-3769](https://pkg.go.dev/vuln/GO-2025-3769), CC-BY-4.0, modified 2026-03-03
- NVD: [CVE-2025-4981](https://nvd.nist.gov/vuln/detail/CVE-2025-4981), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2025-4981 · Whole record: https://cve.day/CVE-2025-4981.json · Rebuilt by cve.day 2026-11-25T22:58:59.427Z
