Tag entries by component

Tag each entry with the components of your product that the vulnerability affects. You can then generate reports, suppression files, and OpenVEX documents for one component. OpenVEX documents tell your customers' tools whether a release is affected by a vulnerability.

Before you start

Tag the entries

  1. Define each tag once under tags, with an id and a description. Acme Shop has one tag per component:

    tags:
      - id: backend
        description: Java server application
      - id: frontend
        description: Web user interface
      - id: worker
        description: Python report worker
      - id: container
        description: Container image that bundles all components
  2. Add the tags of the affected components to each entry:

        tags:
          - backend
          - container
  3. Give each package URL (PURL) of a release the tags of the component it contains. OpenVEX documents list an entry only for release PURLs that share a tag with it. For the release PURLs, see Add and publish releases.

For the rules, see Tags.

Check the result

  1. Validate the file:

    $ vulnlog validate acme-shop.vl.yaml

    A tag that isn’t defined is an error:

    error: acme-shop.vl.yaml: vulnerabilities[CVE-2021-23337].tags[web]: References undefined tags 'web'. Defined tags: backend, container, frontend, worker
  2. Generate a report for one component with --tag:

    $ vulnlog report impact acme-shop.vl.yaml --tag frontend -o frontend-report.html
    Wrote: frontend-report.html

    For the commands that accept --tag, see Filter options.