CVE-2021-3504: Medium severity redhat hivex vulnerability
A flaw was found in libhivex. It's possible to provide a large length value for a node which can read past the end of the file leading to read of arbitrary memory and other potential consequences.
Other sources
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 hivexopen 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.
— MITRE
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
redhat/hivexto a version that resolves this vulnerability.Fixed in 1.3.20 - Upgrade
Upgrade
libhivexto a version that resolves this vulnerability.Fixed in 1.3.20 - Compensating control
If you must process untrusted Windows Registry (hive) files, restrict access to the component that parses hivex inputs (e.g., limit who/what systems can submit hive files) to reduce the chance of crashes affecting availability.
Event History
Frequently Asked Questions
What is CVE-2021-3504?
CVE-2021-3504 is a vulnerability in the hivex library before version 1.3.20 that allows an attacker to read memory beyond its normal bounds or cause the program to crash.
How does CVE-2021-3504 affect Redhat Enterprise Linux 7.0?
CVE-2021-3504 affects Redhat Enterprise Linux 7.0 and can be fixed by updating the hivex package to version 1.3.20 or later.
What is the severity of CVE-2021-3504?
The severity of CVE-2021-3504 is medium with a CVSS score of 5.4.
How can I fix CVE-2021-3504?
To fix CVE-2021-3504, update the hivex package to version 1.3.20 or later.
Where can I find more information about CVE-2021-3504?
You can find more information about CVE-2021-3504 in the references: [GitHub](https://github.com/libguestfs/hivex/commit/8f1935733b10d974a1a4176d38dd151ed98cf381), [Red Hat Bugzilla](https://bugzilla.redhat.com/show_bug.cgi/show_bug.cgi?id=1956204), [Red Hat Security Advisory](https://access.redhat.com/errata/RHSA-2021:2318).