Repository navigation
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Description
- [init] create custom agent md format write constraint permissions
permission:
skill:
"req-create*": deny
- [behavior]
the skill req-create still work
- [debug] log
INFO 2026-01-22T02:30:11 +0ms service=permission permission=skill pattern=req-create ruleset=[{"permission":"","action":"allow","pattern":""},{"permission":"doom_loop","action":"ask","pattern":""},{"permission":"external_directory","pattern":"","action":"ask"},{"permission":"external_directory","pattern":"/Users/mac/.local/share/opencode/tool-output","action":"allow"},{"permission":"external_directory","pattern":"/Users/mac/.local/share/opencode/tool-output/","action":"allow"},{"permission":"question","action":"deny","pattern":""},{"permission":"plan_enter","action":"deny","pattern":""},{"permission":"plan_exit","action":"deny","pattern":""},{"permission":"read","pattern":"","action":"allow"},{"permission":"read","pattern":".env","action":"ask"},{"permission":"read","pattern":".env.","action":"ask"},{"permission":"read","pattern":".env.example","action":"allow"},{"permission":"webfetch","action":"allow","pattern":""},{"permission":"external_directory","action":"allow","pattern":""},{"permission":"write","action":"deny","pattern":""},{"permission":"edit","action":"deny","pattern":""},{"permission":"bash","pattern":"","action":"ask"},{"permission":"bash","pattern":"git diff","action":"allow"},{"permission":"bash","pattern":"git log*","action":"allow"},{"permission":"bash","pattern":"grep ","action":"allow"},{"permission":"read","action":"deny","pattern":""},{"permission":"webfetch","action":"deny","pattern":""},**{"permission":"skill","pattern":"req-create","action":"deny"},**{"permission":"external_directory","pattern":"/Users/mac/.local/share/opencode/tool-output","action":"allow"},{"permission":"external_directory","pattern":"/Users/mac/.local/share/opencode/tool-output/*","action":"allow"}] evaluate
you can see these lines:
first : "permission":"","action":"allow","pattern":""}
then: override {"permission":"skill","pattern":"req-create*","action":"deny"}
Plugins
No response
OpenCode version
1.1.31
Steps to reproduce
just create a custom agent
---
name: phase-router
description: test
mode: primary
permission:
skill:
"req-create*": deny
---
the skill will trigger as normal without any restriction
Screenshot and/or share link
No response
Operating System
macos
Terminal
iterm2
Reacted by justfortheloveof
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Activity
github-actions commentedon Jan 22, 2026
This issue might be a duplicate of existing issues. Please check:
These issues describe similar permission enforcement problems where configured restrictions (especially with wildcard/specific patterns) are not being properly applied.
Feel free to ignore if none of these address your specific case.
khimaros commentedon Feb 7, 2026
is this the same cause as edit permission misbehaving?
for example:
johanlundberg commentedon Feb 9, 2026
I'm seeing the same issue with bash permission rules from config not being enforced.
Config (~/.config/opencode/opencode.json):
bash: {
*: ask,
pytest *: allow,
tail *: allow
}
Command that triggers the permission prompt:
PYTHONPATH=src pytest -vvv src/webapp/tests/test_app.py 2>&1 | tail -20OpenCode correctly decomposes this into pytest * and tail * — the "Always allow" dialog says:
So the pattern matching/decomposition logic works. But two things are broken:
This suggests the session-based "always allow" uses different (working) decomposition logic than the config-based rule evaluation, and even the session-based rules aren't actually being stored/consulted on subsequent calls.
github-actions commentedon Apr 11, 2026
To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.