You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[FEATURE]: Permission action for session utilities (session_move / session_rename) #49825
I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request
Problem: session_move and session_rename do not request a permission action. The session docs state it directly: "These utilities do not request a built-in permission action." No permission profile can gate them: a restricted subagent with deny rules on everything else can still move its own session, or any other session by ID, to any directory.
Moving a session is not cosmetic here. The session location defines which paths count as internal, so a session that moves itself back to the parent checkout undoes its path restrictions.
Request: a permission action for the session utilities, so agent permission profiles can allow, ask, or deny session_move and session_rename like any other tool.
To restate: you'd like session_move and session_rename to request a permission action, so agent permission profiles can allow, ask or deny them like other tools. Right now they don't, as the docs say, so even a restricted subagent can move its own session (or another one by ID) and get around its path restrictions. For comparison, worktree_remove already asks for the edit permission on the worktree directory.
This is current, documented behaviour, so I've marked it as a feature request. The maintainers will consider it. A plugin can't add this, because plugins can't add an action to permission profiles, so it would need a change in core.
Activity
opencodejr commentedon Oct 28, 2026
Thanks for the clear write-up, @TommyC81!
To restate: you'd like
session_moveandsession_renameto request a permission action, so agent permission profiles can allow, ask or deny them like other tools. Right now they don't, as the docs say, so even a restricted subagent can move its own session (or another one by ID) and get around its path restrictions. For comparison,worktree_removealready asks for theeditpermission on the worktree directory.This is current, documented behaviour, so I've marked it as a feature request. The maintainers will consider it. A plugin can't add this, because plugins can't add an action to permission profiles, so it would need a change in core.