kubescape / storage

Apache License 2.0
1 stars 6 forks source link

Vex support #54

Closed slashben closed 10 months ago

slashben commented 10 months ago

PR Type:

Enhancement


PR Description:

This PR introduces support for VEX (Vulnerability Exchange) documents in the Kubescape Storage component. It includes the addition of OpenVulnerabilityExchangeContainer and OpenVulnerabilityExchangeContainerList objects, which are based on the go-vex declarations. These new objects are designed to work with OpenAPI and Kubernetes API. The PR also includes updates to the relevant Go files and Dockerfile.


PR Main Files Walkthrough:

files: `pkg/apis/softwarecomposition/v1beta1/zz_generated.deepcopy.go`: Autogenerated deepcopy functions for new VEX related objects such as Component, Metadata, OpenVulnerabilityExchangeContainer, OpenVulnerabilityExchangeContainerList, Product, Statement, Subcomponent, VEX, and VexVulnerability. `pkg/generated/clientset/versioned/typed/softwarecomposition/v1beta1/fake/fake_openvulnerabilityexchangecontainer.go`: Autogenerated fake clientset for testing OpenVulnerabilityExchangeContainer operations such as Get, List, Watch, Create, Update, Delete, DeleteCollection, and Patch. `pkg/apis/softwarecomposition/v1beta1/types.go`: Definitions of new VEX related types and their methods. `pkg/registry/softwarecomposition/openvulnerabilityexchange/strategy.go`: Implementation of the registry strategy for OpenVulnerabilityExchangeContainer. `pkg/registry/softwarecomposition/openvulnerabilityexchange/etcd.go`: Implementation of the etcd storage for OpenVulnerabilityExchangeContainer. `build/Dockerfile`: Updated the Go builder version to 1.21. `go.mod and go.sum`: Updated the Go dependencies to support the new VEX related changes. `test.yaml`: Test cases related to the new VEX support.

User Description:

Adding support for VEX documents in the Kubescape Storage component:

Both of them are based on https://github.com/openvex/go-vex declarations but were re-defined here due to OpenAPI and K8s API support.

Supporting https://github.com/kubescape/kubevuln/issues/155

codiumai-pr-agent[bot] commented 10 months ago

PR Analysis

How to use

To invoke the PR-Agent, add a comment using one of the following commands: /review [-i]: Request a review of your Pull Request. For an incremental review, which only considers changes since the last review, include the '-i' option. /describe: Modify the PR title and description based on the contents of the PR. /improve [--extended]: Suggest improvements to the code in the PR. Extended mode employs several calls, and provides a more thorough feedback. /ask \<QUESTION>: Pose a question about the PR. /update_changelog: Update the changelog based on the PR's contents.

To edit any configuration parameter from configuration.toml, add --config_path=new_value For example: /review --pr_reviewer.extra_instructions="focus on the file: ..." To list the possible configuration parameters, use the /config command.

github-actions[bot] commented 10 months ago

Summary:

github-actions[bot] commented 10 months ago

Summary:

github-actions[bot] commented 10 months ago

Summary:

github-actions[bot] commented 10 months ago

Summary: