vulnerability: fix search payload key + complete extension coverage#293
Merged
Conversation
The CLI's search dict was sending {"search": <field>, ...} but the
extension's parseSearchOp reads s["field"] — so every --search-* call
was silently dropped server-side. Switch to {"field": ...} and update
the assertion that locked in the wrong shape.
Round out the rest of the surface the extension exposes:
- new flags: --include-enrichment, --filter-via-state on the list
commands; --normalized-package-name on cve hosts;
--rollup-subpackages on host packages; --include-enrichment on
cve get / cve packages
- new subcommands:
- vuln cve epss-history (query_epss_history)
- vuln finding resolve / bulk-resolve / list / reset
(set_finding_resolution, bulk_set_finding_resolution,
list_finding_resolutions, reset_asset_findings)
- vuln snapshot list (query_daily_snapshots)
- help text now mentions lc_risk as a valid --sort-by on cve list
and host packages
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
Summary
_build_searchwas sending{"search": <field>, ...}, butext-vulnerability-reporting'sparseSearchOpreadss["field"]— every--search-*invocation was silently dropped server-side. Switch to{"field": ...}and update the assertion that locked in the wrong shape.ext-vulnerability-reportinguser-facing actions the CLI didn't yet expose:--include-enrichment,--filter-via-state,--normalized-package-name,--rollup-subpackages.vulnerability cve epss-history→query_epss_historyvulnerability finding resolve / bulk-resolve / list / reset→set_finding_resolution,bulk_set_finding_resolution,list_finding_resolutions,reset_asset_findingsvulnerability snapshot list→query_daily_snapshotslc_riskas a valid--sort-byoncve listandhost packages(the extension already supports it).Wire-shape verification
Action names and JSON field names cross-checked against the extension's
RequestHandlersmap and request struct tags inext-vulnerability-reporting/ext/extension.go. Reopen semantics confirmed: omittingresolutionproducesreq.Resolution == nilin Go, whichmaterializeFindingResolutiontreats as reopen.Test plan
test_cli_lazy_loading_regression.pysnapshot extended withfindingandsnapshotsubgroupstoon_formatimport error)🤖 Generated with Claude Code