Repository navigation
fix(sandbox): use unprivileged bubblewrap for bounded previews - #2182
Conversation
|
Just wondering why you closed this |
Merges b978134. The trusted_command resolvers move to strata-core with the rest of the toolkit-free code, so resolve_unprivileged becomes public like resolve.
Review and cleanupCI has not run on this PR. It is a draft, and Merged Review against the description (no linked issue)
Fix pushed
Tests. Both kept. Manual verification. In a throwaway container from the pinned test image, with a setuid-root copy of
Not tested on a real NixOS host. Validation
Not changed
|
Description
Fixes a failure where bounded media/PDF preview rendering fails when
bwrapis installed as a setuid root wrapper (such as/run/wrappers/bin/bwrapon NixOS), because setuidbwraprefuses--unshare-all/ user namespace creation when nested or invoked with unprivileged sandbox flags.bwrapbinary when/run/wrappers/bin/bwrapis first onPATH(including checking/nix/store/*-bubblewrap-*/bin/bwrapwhen needed).bwrappath resolution and fallback behavior.Visual evidence
N/A (sandbox process launch fix for bounded PDF and media previews).
How to test
cargo test --bin strata sandbox::teststo verify thebwrappath resolution unit tests./run/wrappers/bin/bwrapis setuid root (e.g. NixOS), preview a PDF or video file in Strata and verify that bounded preview rendering succeeds without sandbox permission errors.Related issue
None