Skip to content
Fencer Vulns
medium 5.4

CVE-2021-3504 json

A flaw was found in the hivex library in versions before 1.3.20.

published 2021-05-11 5 y ago modified 2026-06-17 4 mo ago also EUVD-2021-26823

cvss
5.4
version 3.1, NVD
cisa kev
Not listed
not in CISA's catalog
epss
1.8%
EPSS 1.8% chance of exploitation in 30 days, percentile 79%
public exploits
0
none known

Summary

A flaw was found in the hivex library in versions before 1.3.20. It is caused due to a lack of bounds check within the hivex_open function. An attacker could input a specially crafted Windows Registry (hive) file which would cause hivex to read memory beyond its normal bounds or cause the program to crash. The highest threat from this vulnerability is to system availability.

Patch / fix

  • redhat hivex 1.3.20
  • hivex Debian 14, Debian 13, Debian 12 1.3.20-1

debian advisories DEBIAN-CVE-2021-3504

  • hivex Ubuntu 18.04 LTS 1.3.15-1ubuntu0.1
  • hivex Ubuntu 20.04 LTS 1.3.18-2ubuntu0.1
  • hivex Ubuntu Pro 14.04 LTS 1.3.9-2ubuntu0.1~esm1
  • hivex Ubuntu Pro 16.04 LTS 1.3.13-1ubuntu0.1~esm1

ubuntu advisories UBUNTU-CVE-2021-3504

Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

  • SLOF RHEL 8 20191022-3.git899d9883.module+el8.3.0+6423+e4cb6418
  • hivex RHEL 8 1.3.18-21.module+el8.4.0+10770+19c037f9
  • netcf RHEL 8 0.2.8-12.module+el8.1.0+4066+0f1aadab
  • libnbd RHEL 8 1.2.2-1.module+el8.3.0+7353+9de0a3cc
  • nbdkit RHEL 8 1.16.2-4.module+el8.3.0+6922+fd575af8
  • libvirt RHEL 8 6.0.0-35.1.module+el8.4.0+11273+64eb94ef
  • nbdfuse RHEL 8 1.2.2-1.module+el8.3.0+7353+9de0a3cc
  • seabios RHEL 8 1.13.0-2.module+el8.3.0+7353+9de0a3cc

red hat advisories RHSA-2021:3061RHSA-2021:2318

  • hivex SLE Module for Development Tools 15 SP3, SLE Module for Development Tools 15 SP2, SLE Module for Basesystem 15 SP3 +2 more 1.3.14-5.3.1
  • hivex SLES for SAP 12 SP5, SLES 12 SP5, SLE Software Development Kit 12 SP5 1.3.10-5.3.1

suse advisories SUSE-SU-2021:1761-1SUSE-SU-2021:1760-1

  • hivex openSUSE Tumbleweed 1.3.21-2.2
  • hivex openSUSE Leap 15.3 1.3.14-5.3.1
  • hivex openSUSE Leap 15.2 1.3.14-lp152.4.3.1

opensuse advisories openSUSE-SU-2024:10845-1openSUSE-SU-2021:1761-1openSUSE-SU-2021:0806-1

  • netcf AlmaLinux 8 0.2.8-12.module_el8.5.0+2608+72063365
  • netcf AlmaLinux 8 0.2.8-12.module_el8.6.0+2880+7d9e3703
  • libnbd AlmaLinux 8 1.2.2-1.module_el8.5.0+2608+72063365
  • nbdkit AlmaLinux 8 1.16.2-4.module_el8.5.0+2608+72063365
  • nbdfuse AlmaLinux 8 1.2.2-1.module_el8.5.0+2608+72063365
  • seabios AlmaLinux 8 1.13.0-2.module_el8.5.0+2608+72063365
  • sgabios AlmaLinux 8 1:0.20170427git-3.module_el8.5.0+2608+72063365
  • sgabios AlmaLinux 8 1:0.20170427git-3.module_el8.6.0+2880+7d9e3703

almalinux advisories ALSA-2021:3061

  • hivex Rocky Linux 8 1.3.18-21.module+el8.4.0+642+7e26f5e1
  • hivex Rocky Linux 8 1.3.18-21.module+el8.5.0+670+c4aa478c
  • netcf Rocky Linux 8 0.2.8-12.module+el8.7.0+1084+97b81f61
  • netcf Rocky Linux 8 0.2.8-12.module+el8.4.0+534+4680a14e
  • netcf Rocky Linux 8 0.2.8-12.module+el8.6.0+847+b490afdd
  • libnbd Rocky Linux 8 1.2.2-1.module+el8.4.0+534+4680a14e
  • nbdkit Rocky Linux 8 1.16.2-4.module+el8.4.0+534+4680a14e
  • libvirt Rocky Linux 8 6.0.0-35.1.module+el8.4.0+642+7e26f5e1

rocky linux advisories RLSA-2021:3061

  • hivex Alpine 3.13 1.3.19-r1
  • hivex Alpine 3.24, Alpine 3.23, Alpine 3.22 +8 more 1.3.19-r2

alpine advisories ALPINE-CVE-2021-3504

Alpine secdb © Alpine Linux, from https://secdb.alpinelinux.org via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

  • hivex CBL-Mariner 2.0 1.3.21-1

azure linux advisories AZL-6472

Azure Linux vulnerability data, Copyright (c) Microsoft Corporation, from https://github.com/microsoft/AzureLinuxVulnerabilityData via OSV, under the MIT licence; changed: normalised to fixed package versions per release. MIT

  • hivex Arch Linux 1.3.20-1

arch linux advisories AVG-1907

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2021-3504 updated cvss 5.4

hivex: Buffer overflow when provided invalid node key length

  • Red Hat Enterprise Linux 6 hivex, perl-hivex, ocaml-hivex, python-hivex
    affected: workaround, no fix planned “Out of support scope”
  • Red Hat Enterprise Linux 8 Advanced Virtualization hivex, perl-hivex, ruby-hivex, ocaml-hivex, python3-hivex
    affected: workaround, no fix available
  • Red Hat CodeReady Linux Builder (v. 8) libnbd 1.2.2-1.module+el8.3.0+7353+9de0a3cc, netcf 0.2.8-12.module+el8.1.0+4066+0f1aadab, nbdfuse 1.2.2-1.module+el8.3.0+7353+9de0a3cc, hivex 1.3.18-21.module+el8.4.0+10770+19c037f9, seabios 1.13.0-2.module+el8.3.0+7353+9de0a3cc, libiscsi 1.18.0-8.module+el8.1.0+4066+0f1aadab, +39 more Red Hat Enterprise Linux AppStream (v. 8) libnbd 1.2.2-1.module+el8.3.0+7353+9de0a3cc, netcf 0.2.8-12.module+el8.1.0+4066+0f1aadab, nbdfuse 1.2.2-1.module+el8.3.0+7353+9de0a3cc, nbdkit 1.16.2-4.module+el8.3.0+6922+fd575af8, hivex 1.3.18-21.module+el8.4.0+10770+19c037f9, seabios 1.13.0-2.module+el8.3.0+7353+9de0a3cc, +88 more
    fixed: vendor fix RHSA-2021:3061
  • Red Hat Enterprise Linux Client (v. 7) hivex 1.3.10-6.11.el7_9, perl-hivex 1.3.10-6.11.el7_9 Red Hat Enterprise Linux Client Optional (v. 7) ruby-hivex 1.3.10-6.11.el7_9, ocaml-hivex 1.3.10-6.11.el7_9, python-hivex 1.3.10-6.11.el7_9 Red Hat Enterprise Linux Server (v. 7) hivex 1.3.10-6.11.el7_9, perl-hivex 1.3.10-6.11.el7_9 Red Hat Enterprise Linux Server Optional (v. 7) ruby-hivex 1.3.10-6.11.el7_9, ocaml-hivex 1.3.10-6.11.el7_9, python-hivex 1.3.10-6.11.el7_9 Red Hat Enterprise Linux Workstation (v. 7) hivex 1.3.10-6.11.el7_9, perl-hivex 1.3.10-6.11.el7_9 Red Hat Enterprise Linux Workstation Optional (v. 7) ruby-hivex 1.3.10-6.11.el7_9, ocaml-hivex 1.3.10-6.11.el7_9, python-hivex 1.3.10-6.11.el7_9
    fixed: vendor fix RHSA-2021:2318
  • Red Hat Enterprise Linux 9 hivex, hivex-libs, perl-hivex, ruby-hivex, ocaml-hivex, python3-hivex
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Exploit prediction

1.85% chance of exploitation in the next 30 days, higher than 79% of all scored CVEs (FIRST EPSS, 2026-11-08).

CVSS scores

assigned by version score vector
NVD 3.1 5.4 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:L
NVD 2.0 5.8 AV:N/AC:M/Au:N/C:P/I:N/A:P

Affected products

  • n/a hivex

Classification

Weakness

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.