Skip to content

security(kubescape): a framework-load failure must fail loudly, not read as a zero-finding clean resultΒ #3024

Description

@devantler

πŸ€– Generated by the Agentic Engineer

Problem

When the posture scanner cannot load its framework, it aborts and persists nothing β€” and the surfaces that consume its output cannot tell that apart from a healthy cluster with no findings. A broken scanner and a compliant cluster read identically.

That is what made #2933 silent for days: the CI posture gate stayed green throughout, and the stored scan data simply stopped moving. Repairing the immediate cause (#3023) restores scanning, but it does not make the next occurrence visible.

This criterion is called out on #2933 as the durable half, worth more than the immediate repair.

Expected behaviour

A scan run that fails to load its framework surfaces as a failure, not as a zero-finding clean result β€” loudly enough that it is noticed without anyone going to look.

Direction

Worth weighing, roughly increasing cost:

  1. Alert on scan staleness. The cheapest reliable signal β€” the stored scan data has an age, and an age past roughly one scan interval means the scanner is not working, whatever the reason. Catches framework-load failures and every other abort cause with one rule.
  2. Alert on the scanner's own failure log/metric, if it exposes one. More precise about cause, but only covers the causes it knows to report.
  3. Fail closed on emptiness. Any consumer treating "zero findings" as a pass should require positive evidence that a scan ran β€” this is the same shape as the CI gate's existing liveness problem.

Option 1 gets most of the value and is the suggested starting point. Note the platform already has an alerting path (Alertmanager runs in the kubescape namespace).

Acceptance criteria

  • A framework-load failure produces a visible signal rather than a silent zero
  • The signal fires on scan staleness too, so any abort cause is covered, not just this one
  • Proven by exercising the failure β€” not by reasoning that the rule would fire
  • No consumer treats an empty/zero posture result as a pass without evidence a scan actually ran

Part of #2933.

Activity

  1. coderabbitai commented on Aug 8, 2026

    @coderabbitai
    Contributor
    πŸ”— Related PRs

    #2443 - fix(kubescape): keep scheduled posture scans local so results persist [merged]
    #2830 - feat(ci): publish Kubescape posture findings to Code Scanning [merged]
    #2876 - feat(security): derive themed, deduped backlog entries from live Kubescape findings [merged]
    #2917 - feat(security): reconcile live Kubescape findings into deduped backlog issues [merged]
    #2973 - fix(ci): fail the deploy when the Cilium rollout gate outruns its window [merged]


    πŸ“ Issue Planner

    Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.

    • Create Plan

    πŸ§ͺ Issue enrichment is currently in open beta.

    You can configure auto-planning by selecting labels in the issue_enrichment configuration.

    To disable automatic issue enrichment, add the following to your .coderabbit.yaml:

    issue_enrichment:
      auto_enrich:
        enabled: false

    πŸ’¬ Have feedback or questions? Drop into our discord!

  2. moved this to πŸ“₯ Backlog in 🌊 Project Boardon Aug 8, 2026
  3. added a commit that references this issue on Aug 19, 2026
  4. moved this from πŸ“₯ Backlog to πŸ‘€ In Review in 🌊 Project Boardon Aug 19, 2026
  5. moved this from πŸ‘€ In Review to πŸƒπŸ»β€β™‚οΈ In Progress in 🌊 Project Boardon Aug 19, 2026
  6. moved this from πŸƒπŸ»β€β™‚οΈ In Progress to πŸ‘€ In Review in 🌊 Project Boardon Aug 19, 2026
  7. moved this from πŸ‘€ In Review to βœ… Done in 🌊 Project Boardon Aug 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Fields

    No fields configured for Security.

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions