Skip to content

feat: validate target path in fill disk Prepare#185

Merged
joshiste merged 7 commits intomainfrom
fix/bm-13788
Feb 18, 2026
Merged

feat: validate target path in fill disk Prepare#185
joshiste merged 7 commits intomainfrom
fix/bm-13788

Conversation

@joshiste
Copy link
Member

@joshiste joshiste commented Feb 12, 2026

Summary

  • Call diskfill.CheckPathWritableRunc (or CheckPathWritableProcess when runc is disabled) in the fill disk action's Prepare method to verify the target directory exists and is writable before starting the attack
  • Add e2e tests for non-existent path and read-only filesystem scenarios
  • Depends on fix: add target path validation for fill disk attacks action-kit#375

Test plan

  • go vet ./... passes
  • Unit tests pass (exthost package)
  • E2e tests pass (including new testFillDiskInvalidPath)

@joshiste joshiste force-pushed the fix/bm-13788 branch 4 times, most recently from eb306d3 to d563f33 Compare February 17, 2026 15:42
Call CheckPathWritableRunc or CheckPathWritableProcess (based on
DisableRunc config) during Prepare to give the user an immediate error
when the target directory does not exist or is on a read-only filesystem.
Test that fill disk fails cleanly for non-existent paths and read-only
tmpfs mounts.
Anonymous structs with json tags are unnecessary since the config is
just serialized to JSON. Plain maps are simpler and more readable.
@joshiste joshiste force-pushed the fix/bm-13788 branch 7 times, most recently from f05026c to 3cca95e Compare February 18, 2026 09:23
@sonarqubecloud
Copy link

@joshiste joshiste merged commit 8f04b13 into main Feb 18, 2026
12 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Feb 18, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant