Skip to content

Document default values for CVE rule data keys in user-facing docs #1753

Description

@st3penta

The defaults for rule data keys like restrict_cve_security_levels, warn_cve_security_levels, restrict_unpatched_cve_security_levels, warn_unpatched_cve_security_levels, and cve_leeway are defined in policy/lib/rule_data/rule_data.rego but are not clearly documented in the Antora-generated documentation.

Currently, the CVE package docs (antora/docs/modules/ROOT/pages/packages/release_cve.adoc) include:

  • Prose mentions of defaults scattered across individual rule descriptions (e.g., "By default, only CVEs of critical and high security level cause a failure").
  • An "Example rule data" YAML block that shows non-default values, which can be confused with the actual defaults.

However, there is no consolidated table or section that explicitly lists each key with its default value. The rule_data.rego file where defaults live is never linked from the docs.

Suggested improvements:

  1. Add a "Default values" section to the CVE package documentation page that lists each rule data key with its actual default value in a table or YAML block clearly labeled as "Defaults" (not "Example").
  2. Consider adding a cross-cutting "Rule Data Defaults Reference" page to the Antora docs that consolidates defaults for all rule data keys across all packages, linking to rule_data.rego as the source of truth.
  3. Ensure the example YAML block is clearly distinguished from the defaults to avoid confusion.

Relevant code locations:

  • Defaults: policy/lib/rule_data/rule_data.rego (lines 36-47)
  • CVE policy: policy/release/cve/cve.rego
  • CVE docs: antora/docs/modules/ROOT/pages/packages/release_cve.adoc
  • Release policy overview: antora/docs/modules/ROOT/pages/release_policy.adoc

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions