Description
LibreDWG is a free C library to read and write DWG files. Prior to 0.14, a specially crafted R13-R2000 DWG can trigger algorithmic resource exhaustion in `decode_R13_R2000` in `src/decode.c`. The class-decoding loop performs `realloc` on every iteration without a sanity check on `num_classes`. Manipulating that field forces an extremely slow allocation loop and denial of service when the file is parsed. Running the parser in a sandbox with memory limits is a workaround rather than a remediation. This issue is fixed in version 0.14.
Published: 2026-10-30
Score: 5.5 Medium
EPSS: n/a
KEV: No
Impact: Denial of Service
Action: Apply Patch
AI Analysis

Impact

The flaw lies in a class‑decoding loop within the R13‑R2000 DWG parser of LibreDWG. The loop calls realloc on every iteration without limiting the number of classes. An attacker can supply a specially crafted DWG file that forces the loop to perform an extreme number of reallocations, draining system memory and causing the parser to become unresponsive. The consequence is a denial of service that affects any application using the vulnerable library to read such a file. This weakness is classified as resource exhaustion and is reflected by the CWE identifiers for unsanitized input and unchecked growth.

Affected Systems

All versions of LibreDWG libredwg released before 0.14 are affected. The problem is present in the free C library before the 0.14 tag and has been corrected starting with that release. Applications that link against older versions of libredwg and parse R13‑R2000 DWG files are susceptible.

Risk and Exploitability

The severity of the vulnerability is moderate with a CVSS score of 5.5. No EPSS data is available, and the issue is not listed in the CISA KEV catalog. The attack vector is inferred to be local: an attacker who can supply a crafted DWG file to the application or service that uses libredwg can trigger the denial of service. Since the flaw causes resource exhaustion, it requires the target process to be running; it does not provide an escalation or remote code execution pathway. The exploitation likelihood is therefore limited to scenarios where untrusted files are processed.

Generated by OpenCVE AI on October 30, 2026 at 21:36 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update LibreDWG to version 0.14 or later, which contains the fix for the reallocation loop.
  • If updating is not immediately possible, run any DWG parsing operation in a sandboxed environment with strict memory limits to contain the allocation attack.
  • Validate input DWG files for class count or size before passing them to libredwg to mitigate the possibility of triggering the loop.

Generated by OpenCVE AI on October 30, 2026 at 21:36 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Fri, 30 Oct 2026 21:45:00 +0000

Type Values Removed Values Added
First Time appeared Libredwg
Libredwg libredwg
Vendors & Products Libredwg
Libredwg libredwg

Fri, 30 Oct 2026 20:45:00 +0000

Type Values Removed Values Added
Description LibreDWG is a free C library to read and write DWG files. Prior to 0.14, a specially crafted R13-R2000 DWG can trigger algorithmic resource exhaustion in `decode_R13_R2000` in `src/decode.c`. The class-decoding loop performs `realloc` on every iteration without a sanity check on `num_classes`. Manipulating that field forces an extremely slow allocation loop and denial of service when the file is parsed. Running the parser in a sandbox with memory limits is a workaround rather than a remediation. This issue is fixed in version 0.14.
Title LibreDWG: excessive class-decoding reallocation in R13-R2000 DWG parsing
Weaknesses CWE-400
CWE-789
References
Metrics cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H'}


Subscriptions

Libredwg Libredwg
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-30T20:36:09.037Z

Reserved: 2026-07-13T17:09:57.573Z

Link: CVE-2026-62254

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-30T21:17:13.370

Modified: 2026-10-30T21:17:13.370

Link: CVE-2026-62254

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-30T21:30:11Z

Weaknesses
  • CWE-400

    Uncontrolled Resource Consumption

  • CWE-789

    Memory Allocation with Excessive Size Value