feat(vulns): add check-sca-patches command for osv patch validation#20
Open
gabrielvmayer wants to merge 3 commits intomainfrom
Open
feat(vulns): add check-sca-patches command for osv patch validation#20gabrielvmayer wants to merge 3 commits intomainfrom
gabrielvmayer wants to merge 3 commits intomainfrom
Conversation
…g when running check-sca-patches
…responses in check-sca-patches
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
This PR introduces a new
check-sca-patchescommand topython -m conviso.app vulnsdesigned to identify and cross-reference available patches for open SCA vulnerabilities.It automatically queries the Conviso Platform for open
SCA_FINDINGvulnerabilities missing apatchedVersionand integrates with the public Open Source Vulnerabilities (OSV) API (api.osv.dev) to discover fixed versions.Key features include:
GHSA-*from the GitHub Advisory Database) if the primary CVE entry lacks patch details, ensuring high discovery rates.ECOSYSTEManddatabase_specificranges instead of raw git commit hashes.--severities,--status,--cves,--asset-tags,--asset-ids) leveraging native GraphQL parameters.How to Test
Run
python -m conviso.app vulns check-sca-patches --helpConfirm the new command and standard filtering options are listed.
Run
python -m conviso.app vulns check-sca-patches --company-id <ID>Expected behavior: The CLI should query the company's open SCA vulnerabilities, query OSV resolving any aliases for missing patches, and render a formatted table displaying the new
OSV Patched Versioncolumn.Run
python -m conviso.app vulns check-sca-patches --company-id <ID> --status IDENTIFIED --severities HIGHExpected behavior: The tool must only process and query patches for
IDENTIFIEDandHIGHseverity vulnerabilities.