Skip to content

feat(plugin): add SetSandboxBinary FFI for custom executor path#144

Merged
cyyever merged 1 commit intomainfrom
feat/sandbox-env-override
Mar 27, 2026
Merged

feat(plugin): add SetSandboxBinary FFI for custom executor path#144
cyyever merged 1 commit intomainfrom
feat/sandbox-env-override

Conversation

@cyyever
Copy link
Copy Markdown
Collaborator

@cyyever cyyever commented Mar 27, 2026

Summary

Add SetSandboxBinary() to configure a custom sandbox executor command via the LibcrustSetSandboxBinary FFI export. The host calls this before StartProtect to specify its own binary (e.g. "app sandbox-wrap"), eliminating the need to bundle a separate bakelens-sandbox binary.

The command is passed as a JSON array to handle paths with spaces on Windows. Discovery order: SetSandboxBinary override → LookPath.

Test plan

  • go build ./... passes
  • go test -race ./... passes
  • Tested manually (describe below)

Security checklist

  • No new path traversal or glob bypass vectors
  • No secrets or credentials in code

Add SetSandboxBinary() to configure a custom sandbox executor command
via the LibcrustSetSandboxBinary FFI export. The host calls this before
StartProtect to specify its own binary (e.g. "app sandbox-wrap"),
eliminating the need to bundle a separate bakelens-sandbox binary.

The command is passed as a JSON array to handle paths with spaces
on Windows. Discovery order: SetSandboxBinary override → LookPath.
@cyyever cyyever force-pushed the feat/sandbox-env-override branch from 72989b7 to 2ceffb2 Compare March 27, 2026 06:55
@cyyever cyyever merged commit f0ab169 into main Mar 27, 2026
5 checks passed
@cyyever cyyever deleted the feat/sandbox-env-override branch March 27, 2026 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant