# CVE-2021-21899: librecad: A code execution vulnerability exists in the dwgCompressor::copyCompBytes21 functionality of LibreCad libdxfrw 2.2.0-...

CVE-2021-21899 is fixed in 2 products on 1 platform, first by DEBIAN-CVE-2021-21899, released November 19, 2021. It is not reported as exploited. Patch Radar priority: High.

- Web page: https://patchblox.com/security/cve/CVE-2021-21899
- Priority: High
- CVSS: 8.8 (high)
- EPSS: 0.0276
- CISA KEV: not listed
- Exploited (vendor report): no
- Publicly disclosed: no
- Published: Nov 19, 2021

## Description

A code execution vulnerability exists in the dwgCompressor::copyCompBytes21 functionality of LibreCad libdxfrw 2.2.0-rc2-19-ge02f3580. A specially-crafted .dwg file can lead to a heap buffer overflow. An attacker can provide a malicious file to trigger this vulnerability.

## Where it's fixed

| Platform | Product | Fixed in | Fix | Released |
|---|---|---|---|---|
| Linux | librecad Debian 12.15 (bookworm) | 2.1.3-2 | [DEBIAN-CVE-2021-21899](https://patchblox.com/security/data/fix/linux/debian-cve-2021-21899.md) | Nov 19, 2021 |
| Linux | librecad Debian 13.5 (trixie) | 2.1.3-2 | [DEBIAN-CVE-2021-21899](https://patchblox.com/security/data/fix/linux/debian-cve-2021-21899.md) | Nov 19, 2021 |
| Linux | librecad Debian 14 | 2.1.3-2 | [DEBIAN-CVE-2021-21899](https://patchblox.com/security/data/fix/linux/debian-cve-2021-21899.md) | Nov 19, 2021 |
| Linux | librecad Ubuntu 18.04.6 LTS (bionic) | 2.1.2-1ubuntu0.1~esm1 | [librecad 2.1.2-1ubuntu0.1~esm1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-librecad-2.1.2-1ubuntu0.1-esm1.md) | Jan 25, 2022 |
| Linux | librecad Ubuntu 20.04 LTS (focal) | 2.1.3-1.2+deb10u1build0.20.04.1 | [librecad 2.1.3-1.2+deb10u1build0.20.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-focal-librecad-2.1.3-1.2-deb10u1build0.20.04.1.md) | Jan 25, 2022 |
| Linux | librecad-data Ubuntu 18.04.6 LTS (bionic) | 2.1.2-1ubuntu0.1~esm1 | [librecad-data 2.1.2-1ubuntu0.1~esm1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-librecad-data-2.1.2-1ubuntu0.1-esm1.md) | Jan 25, 2022 |
| Linux | librecad-data Ubuntu 20.04 LTS (focal) | 2.1.3-1.2+deb10u1build0.20.04.1 | [librecad-data 2.1.3-1.2+deb10u1build0.20.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-focal-librecad-data-2.1.3-1.2-deb10u1build0.20.04.1.md) | Jan 25, 2022 |

---

Data as of 2026-11-08T19:12:23Z UTC. Source: Patchblox Patch Radar (https://patchblox.com/security/patch-radar). Patchblox finds out-of-date software on Windows, macOS and Linux and updates it through release rings: https://patchblox.com/demo

Free to use with attribution: show "Data: Patchblox Patch Radar" with a link to https://patchblox.com/security/patch-radar. Terms, including what needs a written agreement: https://patchblox.com/security/patch-radar/use-the-data

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.
