Skip to content

🐛 fix: bound snap package enumeration over ssh#6878

Merged
syrull merged 1 commit intomainfrom
syl/mql-snap-enumeration-fix
Mar 11, 2026
Merged

🐛 fix: bound snap package enumeration over ssh#6878
syrull merged 1 commit intomainfrom
syl/mql-snap-enumeration-fix

Conversation

@syrull
Copy link
Copy Markdown
Contributor

@syrull syrull commented Mar 11, 2026

Summary

  • replace the recursive /snap walk with a CLI-first snap enumeration path plus a bounded filesystem fallback
  • use snap list to identify active snaps on run-command targets, then read the exact /snap/<name>/<rev>/meta/snap.yaml manifest to preserve package metadata
  • for filesystem-only targets, inspect only /snap/<name>/current/meta/snap.yaml or direct numeric revision manifests and pick the highest valid revision
  • degrade safely for expected snap failures so Debian package enumeration no longer fails or times out because of snap discovery

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Snap package enumeration over SSH no longer walks the entire filesystem, using bounded directory reads and CLI enrichment instead.

Comment thread providers/os/resources/packages/snap_packages.go
Comment thread providers/os/resources/packages/snap_packages.go
@github-actions
Copy link
Copy Markdown
Contributor

Test Results

5 365 tests   5 361 ✅  2m 18s ⏱️
  411 suites      4 💤
   31 files        0 ❌

Results for commit e72d61c.

@syrull syrull merged commit ed01e23 into main Mar 11, 2026
23 checks passed
@syrull syrull deleted the syl/mql-snap-enumeration-fix branch March 11, 2026 16:25
@syrull syrull self-assigned this Mar 11, 2026
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 11, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant