Repository navigation
Conversation
…aliases Update ExtractReferencedVulns to place all GHSA and SNYK identifiers extracted from CVE reference URLs into the `related` field rather than conditionally placing single matches into `aliases`. Previously, when a CVE referenced only a single GHSA or SNYK URL, ExtractReferencedVulns added that identifier to `aliases`. However, if multiple distinct CVEs each referenced the same single umbrella advisory, OSV's transitive alias computation (`relations`) would merge those distinct CVEs into the same alias group. Because ingested GHSA records already declare their corresponding CVE aliases and the `relations` service computes aliases bidirectionally, extracting aliases from CVE reference URLs is redundant for valid aliases while risking false transitive aliasing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Update
ExtractReferencedVulnsinvulnfeedsso that all referencedGHSA-*andSNYK-*vulnerability IDs extracted from reference URLs are placed into therelatedfield instead of conditionally being added toaliases.Motivation & Background
Previously,
ExtractReferencedVulnsonly placed extracted identifiers intorelatedif more than one match was found (len > 1), while single matches were placed intoaliases. This caused issues:aliases. OSV'srelationsjob computes transitive connected components of aliases, causing distinct CVEs to be merged into the same alias group and falsely aliased to each other.SNYK-*IDs inaliasesresulted in dangling alias identifiers without backing records in OSV. Placing them inrelatedcorrectly references them without affecting alias resolution.aliasesfield. Because OSV'srelationsservice computes aliases bidirectionally (A.aliases = [B] <=> B.aliases = [A]), the CVE record automatically receives legitimate GHSA aliases from the ingested GHSA records without needing to infer aliases from CVE reference URLs.The
id != cveIDalias check is preserved so that wrapper converters (such ascmd/pypicreatingPYSEC-*IDs) continue to record their underlying CVE ID inaliases.