Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…
EPSS 0.1%top 97%

CVE-2026-16118: Heap-based Buffer Overflow in xdg xdgmime

0
High
VulnerabilityCVE-2026-16118cvecve-2026-16118
Published: 07/17/2026 (07/17/2026, 19:44:40 UTC)
Source: CVE Database V5
Vendor/Project: xdg
Product: xdgmime

Description

A flaw was found in xdgmime. A heap-based buffer overflow can be triggered in _xdg_mime_magic_parse_magic_line() in the xdgmimemagic.c file on little-endian systems when an attacker-controlled MIME magic file in a user-writable XDG data location (e.g., in the $XDG_DATA_HOME/mime/magic path) is parsed by an application performing MIME type detection (e.g., via g_content_type_guess()). When performing byte-swap, incorrect pointer arithmetic on the write side causes an out-of-bounds write of 2 bytes, resulting in an application crash or memory corruption.

CVSS v3.1

Score 7.1high

Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
High
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:H

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/02/2026, 20:31:42 UTC

Technical Analysis

The vulnerability in xdgmime arises from a heap-based buffer overflow triggered in the _xdg_mime_magic_parse_magic_line() function within xdgmimemagic.c on little-endian systems. When an application performs MIME type detection (e.g., via g_content_type_guess()) and parses a crafted MIME magic file placed by an attacker in a user-writable XDG data location (such as $XDG_DATA_HOME/mime/magic), incorrect pointer arithmetic during byte-swapping leads to a 2-byte out-of-bounds write. This can cause application crashes or memory corruption. The vulnerability requires local access to place the malicious MIME magic file and user interaction to trigger parsing. The CVSS vector indicates low attack complexity, no privileges required, but user interaction is needed, with no confidentiality impact but high integrity and availability impact.

Potential Impact

Successful exploitation can cause application crashes or memory corruption due to a heap-based buffer overflow. This may lead to denial of service or potentially allow an attacker to alter application behavior or memory contents, impacting integrity and availability. There is no indication of confidentiality impact. Exploitation requires local ability to write attacker-controlled MIME magic files and user interaction to trigger MIME type detection parsing.

Mitigation Recommendations

Patch status is not yet confirmed — check the vendor advisory at https://access.redhat.com/security/cve/CVE-2026-16118 for current remediation guidance. Until an official fix is available, avoid running applications that perform MIME type detection on untrusted or user-writable XDG data locations. Restrict write permissions to XDG data directories to trusted users only. Monitor the vendor advisory for updates on patches or official mitigations.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
redhat
Date Reserved
2026-07-17T15:50:21.345Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null
Vendor Advisory Urls
[{"url":"https://access.redhat.com/security/cve/CVE-2026-16118","vendor":"Red Hat"}]

Threat ID: 6a5b5eae2d1edb114c7fb30d

Added to database: 07/18/2026, 11:08:30 UTC

Last enriched: 08/02/2026, 20:31:42 UTC

Last updated: 09/01/2026, 10:52:07 UTC

Views: 70

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses