Skip to content

grcov has an out of bounds write triggered by crafted coverage data

Moderate severity GitHub Reviewed Published Feb 10, 2025 to the GitHub Advisory Database • Updated Feb 10, 2025

Package

cargo grcov (Rust)

Affected versions

< 0.8.20

Patched versions

0.8.20

Description

Function grcov::covdir::get_coverage uses the unsafe function get_unchecked_mut without validating that the index is in bounds.

This results in memory corruption, and could potentially allow arbitrary code execution provided that an attacker can feed the tool crafted coverage data.

References

Published to the GitHub Advisory Database Feb 10, 2025
Reviewed Feb 10, 2025
Last updated Feb 10, 2025

Severity

Moderate

EPSS score

Weaknesses

CVE ID

No known CVE

GHSA ID

GHSA-qm2p-4w45-v2vr

Source code

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.