{"answers":{"affected":"3 open source packages ship an affected version, including grcov.","exploited":"There is no known exploitation of GHSA-qm2p-4w45-v2vr in the wild and no public exploit code.","fix":"Upgrade grcov to a fixed version for your release line: 0.8.20 or 0.8.21-0.","what":"GHSA-qm2p-4w45-v2vr is a memory corruption vulnerability in grcov, published on 13 Jan 2025. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for GHSA-qm2p-4w45-v2vr and fix it if it is affected.\n\nWhat it is: GHSA-qm2p-4w45-v2vr is a memory corruption vulnerability in grcov, published on 13 Jan 2025. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of GHSA-qm2p-4w45-v2vr in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- grcov (crates.io): affected all versions; fixed in 0.8.20\n- grcov (crates.io): affected all versions; fixed in 0.8.20\n- grcov (crates.io): affected from 0.0.0-0; fixed in 0.8.21-0\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/GHSA-qm2p-4w45-v2vr/ (Markdown: https://insights.sbomify.com/GHSA-qm2p-4w45-v2vr/index.md)","id":"GHSA-qm2p-4w45-v2vr","markdown":"https://insights.sbomify.com/GHSA-qm2p-4w45-v2vr/index.md","name":"GHSA-qm2p-4w45-v2vr","record":{"aliases":["RUSTSEC-2025-0005"],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"adjacent_or_local","non_default_config":false,"product_category":"Rust coverage tool","requires_auth":"none","summary":"An attacker can achieve arbitrary code execution by providing crafted coverage data to the grcov tool, which fails to validate array indices.","user_interaction":"required","vuln_class":"memory_corruption"},"analysis_generated_by":"qwen3.8-flash-next","assigner":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"Function `grcov::covdir::get_coverage` uses the `unsafe` function `get_unchecked_mut` without validating that the index is in bounds.\n\nThis results in memory corruption, and could potentially allow arbitrary code execution provided that an attacker can feed the tool crafted coverage data.","ecosystems":["crates.io"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"grcov has an out of bounds write triggered by crafted coverage data","id":"GHSA-qm2p-4w45-v2vr","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"crates.io","product":null,"products":[],"type":"memory_corruption","year":"2025"},"n_packages":3,"n_references":null,"packages":[{"ecosystem":"crates.io","fixed":["0.8.20"],"introduced":["0"],"last_affected":[],"package":"grcov","purl":null,"source":"GHSA-qm2p-4w45-v2vr"},{"ecosystem":"crates.io","fixed":["0.8.20"],"introduced":["0"],"last_affected":[],"package":"grcov","purl":"pkg:cargo/grcov","source":"GHSA-qm2p-4w45-v2vr"},{"ecosystem":"crates.io","fixed":["0.8.21-0"],"introduced":["0.0.0-0"],"last_affected":[],"package":"grcov","purl":"pkg:cargo/grcov","source":"RUSTSEC-2025-0005"}],"products":null,"published":"2025-01-13","related":[],"sources":[{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"open","licence":"CC0 1.0","name":"RustSec","prefix":"RUSTSEC"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":null,"updated":null,"vendors":null},"summary":"An attacker can achieve arbitrary code execution by providing crafted coverage data to the grcov tool, which fails to validate array indices.","url":"https://insights.sbomify.com/GHSA-qm2p-4w45-v2vr/"}