Libmodulemd: libmodulemd: out-of-bounds read when emitting rpm-map artifacts
Impact
A flaw was found in libmodulemd. In the module stream v2 rpm-map emission path, an inner loop incorrectly uses the count of digest algorithms as its bound instead of the number of checksums in the current digest table. Crafted modulemd v2 metadata with multiple digest types can trigger an out-of-bounds read during YAML serialization, typically causing a crash and resulting in a denial of service.
Source excerpt · redhatWhat to do
Until a fixed package is available, avoid round-tripping untrusted modulemd v2 documents that include artifacts.rpm-map. If untrusted metadata must be accepted, reject or strip rpm-map content with multiple digest algorithms before serializing the parsed object.
Affected packages
Affected products
Vendor version evidence. Product records are separate from automatic dependency matching.
Red Hat · Red Hat Enterprise Linux 10
Other versions: affected
| Version / range | Source status |
|---|
Red Hat · Red Hat Enterprise Linux 8
Other versions: affected
| Version / range | Source status |
|---|
Red Hat · Red Hat Enterprise Linux 9
Other versions: affected
| Version / range | Source status |
|---|
Red Hat · Red Hat Hardened Images
Other versions: affected
| Version / range | Source status |
|---|
Red Hat · Red Hat OpenShift Container Platform 4
Other versions: affected
| Version / range | Source status |
|---|
Red Hat · Red Hat OpenShift Container Platform 4
Other versions: affected
| Version / range | Source status |
|---|
Original source description
A flaw was found in libmodulemd. In the module stream v2 rpm-map emission path, an inner loop incorrectly uses the count of digest algorithms as its bound instead of the number of checksums in the current digest table. Crafted modulemd v2 metadata with multiple digest types can trigger an out-of-bounds read during YAML serialization, typically causing a crash and resulting in a denial of service.