Skip to content

v0.13.0

Choose a tag to compare

@dyoshikawa dyoshikawa released this 25 Oct 03:48
8d60f52

What's Changed

Escalate rules: operations that always go to a human (opt-in)

reviewer.instructions are guidance a model may still get wrong. The new top-level escalate option lists operations that are escalated to a human before any reviewer sees them, with every backend and both plugin API generations. In on-ask mode the OpenCode prompt stays; in all-tools mode the tool is blocked with the matched rule as the reason.

"options": {
  "escalate": [
    { "action": "shell", "resource": "*git push*" },
    { "action": "webfetch" },
    { "action": "*", "resource": "*.env" }
  ]
}
  • action matches the permission action (on-ask) or the tool name (all-tools); the shell is shell on OpenCode 2.x and bash on 1.x.
  • resource uses OpenCode's * / ? wildcards and is matched against every string value, whole, per line and per shell word, ignoring case and whitespace runs. Matching never uses a regular expression.
  • What write / edit / multiedit write is not matched, and an apply_patch patch is matched through its file headers, so a path rule does not fire on code that merely mentions a path.
  • Inputs too deep or too large to check escalate under any rule for their action.
  • Rules are a deterministic floor, not a sandbox: keep OpenCode deny permissions for what must never run.

Credentials are redacted before review, and reviews in flight are capped

Behavior change: by default, the state sent to the reviewer's provider now has credential values replaced by markers such as [REDACTED]: the configured reviewer.decision / reviewer.chat API keys, private key blocks, URL passwords, well-known token formats, and secret-shaped values after Authorization: / Bearer, --password / --token-style flags, or in *_KEY= / *_TOKEN= / *_SECRET= / *_PASSWORD= assignments. The tool OpenCode runs is never changed. Redaction is deliberately conservative so that crafted text cannot hide a path, host, URL or command from the reviewer. Add patterns with reviewer.redact.patterns, or turn it off with reviewer.redact.enabled: false.

Behavior change: at most reviewer.maxConcurrentReviews reviews (default 4, 1–32) run at once. More wait for a free slot for up to reviewer.timeoutMs and then escalate.

See What reviewers receive.

  • feat: redact credentials and cap concurrent reviews by @dyoshikawa in #77

Hardening of the all-tools native-ask grant

  • With allToolsNativeAsks: "review", a native ask is only answered when the live tool call still has the same tool and input as the one reviewed. A call whose input changed during review now fails closed in every all-tools mode.
  • allToolsNativeAsks: "review" is now rejected at startup with mode: "on-ask" and on the OpenCode 1.x plugin API, where it does nothing.
  • fix: refuse native ask grants for calls rewritten after review by @dyoshikawa in #70

Configuration that does nothing is rejected

reviewer.agent.cleanupSessions is now rejected at startup on the OpenCode 1.x plugin API and with the SDK runtimes, instead of being silently ignored. Invalid options are reported with an Invalid auto-approval plugin options: prefix.

  • fix: assert reviewer session cleanup and reject it where it does nothing by @dyoshikawa in #73

Security audit follow-ups

  • A reviewer reply with too many braces to rule out a conflicting second verdict is no longer trusted, unless it is unambiguous.
  • In all-tools mode on OpenCode 2.x, only the plugin's own reviewer sessions skip review; an agent that merely shares the reviewer's name no longer does.
  • The Codex SDK minimum version (0.163.0) is now also enforced for an installed copy, and a prerelease ranks below its release. The CommonJS build cannot locate an installed copy's version, so it needs reviewer.agent.codexSdk.path.
  • fix: close the security audit leftovers and the PR #66 follow-ups by @dyoshikawa in #76

Maintenance

  • ci: regenerate AI tool configurations before the generated-file check by @dyoshikawa in #71
  • chore: resolve the development dependency advisories by @dyoshikawa in #72

Contributors

Full Changelog: v0.12.0...v0.13.0