CVE-2024-4182: Mattermost crashes web clients via a malformed custom status
4.3
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.41743%
CWE
Published
4/26/2024
Updated
4/26/2024
KEV Status
No
Technology
Go
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| github.com/mattermost/mattermost-server | go | >= 8.1.0, <= 8.1.11 | 8.1.12 |
| github.com/mattermost/mattermost-server | go | >= 9.4.0, <= 9.4.4 | 9.4.5 |
| github.com/mattermost/mattermost-server | go | >= 9.5.0, <= 9.5.2 | 9.5.3 |
| github.com/mattermost/mattermost-server | go | >= 9.6.0-rc1, <= 9.6.0 | 9.6.1 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from two key gaps:
- User.IsValid in user.go failed to validate custom status data integrity before persistence. The patch added ValidateCustomStatus() checks here to reject invalid JSON.
- The webapp selector in custom_status.ts used JSON.parse without try-catch blocks. The patch added error handling to prevent crashes when parsing corrupted data. Both functions directly contributed to the improper handling of exceptional conditions (CWE-754).