Repository navigation
opencode-injection-guard@0.2.0
·
5 commits
to main
since this release
-
scanPatternsis now required — no implicit scanning — default changed from["bash:*", "webfetch:*", "task:*"]to[]. The guard does nothing unless you explicitly set which tools to scan:echo '{"scanPatterns":["bash:*","webfetch:*"]}' > .opencode/injection-guard.json
Or via env var:
OPENCODE_INJECTION_GUARD='{"scanPatterns":["bash:*","webfetch:*"]}' opencode -
Env var now takes highest priority — when both a config file and
OPENCODE_INJECTION_GUARDenv var are set, the env var wins for any field it specifies:OPENCODE_INJECTION_GUARD env var (highest priority) | .opencode/injection-guard.json (file, find-up) | hardcoded defaults (lowest priority) -
Per-session scan patterns for Kimaki — when running inside Kimaki (
KIMAKI=1), scan patterns can be overridden per-session via a temp file at/tmp/kimaki-injection-guard/<sessionId>.json. Lets Kimaki enable/disable scanning per session without affecting other sessions or standalone OpenCode usage.